GCP Pub/Sub
Aidbox has support of GCP Pub/Sub integration
Note
This is old, not stable version.
Since version 2309 Aidbox has GCP Pub/Sub integration via Topic-Based Subscriptions, which is ready for production use.
FHIR topic-based subscriptionsGCP Pub/Sub
Any create, update, or delete operations on all resources in Aidbox may be published to a GCP Pub/Sub topic.
In order to enable GCP Pub/Sub integration you need to provide a few env variables:
Aidbox doesn't create the topic, specified in BOX_SUBSCRIPTIONS_PUBSUB_TOPIC
.
On every resource update, Aidbox will publish to GCP Pub/Sub message with empty body and few attributes:
resourceType — resource type of updated resource
id — id of the updated resource
versionId — version id of the updated resource
action — action (create, update, delete)
box-id — Aidbox id.
Running Pub/Sub Integration with a local emulator
You can enable GCP Pub/Sub integration to work with a local Pub/Sub emulator. In that case, you need to provide these env variables:
Publish a message before a resource is saved to a Database
By default message about change is published after the change is written to a Database. This approach makes the situation possible when a change was performed, but the message was not published.
Set
to publish a message before a change is saved to Database.
versionId
attribute of a message will store the id of the version before the update of nil
for create
operation.
Specify resource types and boxes for which to publish notification
By default, messages for all resource types from all boxes are published. To specify, what resource types and boxes should trigger a notification set
Multibox: specify topic per box
It's possible to specify different topics per box. Topic without box specification treated as default.
Last updated
Was this helpful?