Page Properties | ||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||||||||
Ressourcespartly described in Tutorial Extending Functionalities by using System Hooks Remarksconcept article linking to the respective tutorials |
...
The AMQP Hooks allow for asynchronous reactions to events like object creation, update or deletion. There are different types of AMQP Hooks available, each of them specialized for selected function calls. The messages contain the properties of the object metadata which is the target of the function call triggering the AMQP Hook. The action code is included in there in the message as well as the history code that is added to the audit trail. The AMQP Hook can be triggered by any endpoint that induced the characteristic history codes of the AMQP Hook kann ich das irgendwo in der Endpunktdoku dann erkennen?.
...
The parameters of the AMQP Hook are specified in JSON format. In the configuration file ich würde den hier auch noch mal nennen, multiple AMQP Hooks can be defined in a list called amqp
. It must however be observed that only one messaging queue can be used. The messaging queue specified for the first defined AMQP Hook will apply to all following AMQP Hook definitions as well. Of course, the messaging system needs to support AMQP 1.0. Any changes to the AMQP Hook configuration require a restart of the API-gateway service.
...
In our example of asynchronous full-text indexing, the API-gateway service is responsible for evaluating the system hook. To apply the configuration, the API-gateway service must be restarted after saving the configuration file. Messages will then be send to the messaging system haben wir hier was zur Installation for the import of compound documents.
AMQP Hook Types
dms.response.insert
Response Format | JSON | |||||
---|---|---|---|---|---|---|
Description | ||||||
Example Predicate | 1) reaction to every object creation: 2) reaction to every object creation having a content 3) reaction to every object creation without content: | |||||
Action Codes - History Codes | 101 - OBJECT_CREATED_WITH_CONTENT 100 - OBJECT_CREATED | |||||
Example Response |
|
dms.response.update
Response Format | JSON | |||||
---|---|---|---|---|---|---|
Description | ||||||
Example Predicate | 1) reaction to every object update: 2) reaction to every tag creation: 3) reaction to every tag deletion: 4) reaction to every metadata update: 5) reaction to every content update: | |||||
Action Codes - History Codes | 300 - OBJECT_METADATA_CHANGED 301 - OBJECT_DOCUMENT_CHANGED 303 - OBJECT_UPDATE_CONTENT_MOVED 110 - OBJECT_TAG_CREATED 310 - OBJECT_TAG_UPDATED 210 - OBJECT_TAG_DELETED | |||||
Example Response |
|
dms.response.insert
Response Format | JSON | |||||
---|---|---|---|---|---|---|
Description | ||||||
Example Predicate | 1) reaction to every object deletion: 2) reaction to every object 3) reaction to every object | |||||
Action Codes - History Codes | 200 - OBJECT_DELETED 202 - OBJECT_FLAGGED_FOR_DELETE | |||||
Example Response |
|
Summary
In this article, we gave an introduction to AMQP Hooks, covered the configuration using the example of asynchronous full text indexing and provide a list of all AMQP Hooks available. Check out Webhooks which are the second type of System Hooks in yuuvis® Momentum.
...