G2P Registry Datashare: WebSub
Last updated
Was this helpful?
Last updated
Was this helpful?
g2p_registry_datashare_websub
G2P Registry Datashare: WebSub
This module adds functionality that enables sharing of Registry data to external partners via WebSub.
Refer to feature documentation.
Automatically publishes the configuration to WebSub when a config record is created.
There is also an Odoo action to manually sync the current selected config data to WebSub.
Automatically publishes event data to WebSub whenever the particular event is raised.
There is also a button which can be used to manually publish selected records
Name
Can be a combination of Partner name and event type. (Each Datashare config should considered unique for the combination of partner_id + event_type.)
Partner ID
This should exactly match the Keycloak client ID of the partner.
Event Type
This decides which event type this partner is interested in. If the partner is interested in more than one event duplicate this entire config for the other event_type(s).
Data Transform JQ Expression
This JQ filter will be used to convert original data into final data that is supposed to be sent to partner. The following fields are available in the original JSON data.
web_base_url
: Root URL to access Social Registry.
publisher
: This configuration record data itself - available as JSON.
curr_datetime
: Current Datetime
data
: Only the part of the data that is changed. For advanced usage only. (TODO: elaborate)
record_data
: Entire Record data - as JSON.
extra_fields
: Any extra fields configured - available as JSON with the key being the extra field's name.
Condition JQ Expression
For advanced usage only. (TODO: elaborate)
true
Extra Fields
Table of set of additional fields to be computed before sending data to partner. Can contain signed JWT, etc.
Topic Joiner
For advanced usage only. Final WebSub topic name will be constructed as {partner_id}{topic_joiner}{event_type}
.
/
Encryption Provider ID
Encryption Provider to be used for signing the JWT, etc. Leave blank to take the default encryption provider. This will decide whether to use keymanager (if so which keys in keymaanger) or any custom encryption provider.
WebSub Base URL
WebSub Hub Url. This should be K8s internal service url.
http://websub/hub
WebSub Auth URL (Token Endpoint)
Keycloak OAuth2 Token endpoint
WebSub Auth Client ID
Keycloak Client ID of Publisher (Social Registry). (Not the partner)
openg2p-sr-<ns>
WebSub Auth Client Secret
Keycloak Client Secret of Publisher (Social Registry). (Not the partner)
WebSub Auth Grant Type
client_credentials
WebSub API Timeout
Timeout to be used while publishing data to WebSub. Given in seconds.
10
Active
If this is off, this config will not be considered for automatic publishing of data when the event occurs. Manual Publish can still be used.
true