completed initial impl
This commit is contained in:
@@ -0,0 +1,50 @@
|
||||
# API Documentation: MQ Activiti Extension: `mqPublishDelegate`
|
||||
|
||||
*Author*: [brian@inteligr8.com](mailto:brian@inteligr8.com)
|
||||
*Since Version*: 1.0
|
||||
|
||||
|
||||
This delegate sends a message to an MQ queue.
|
||||
|
||||
*See Also*: [`mqSubscribeReplyDelegate`](bean-mqSubscribeReplyDelegate.md)
|
||||
*See Also*: [`mqSubscribeDelegate`](bean-mqSubscribeDelegate.md)
|
||||
|
||||
## <a name="delegate"></a> Delegate Expression Uses
|
||||
|
||||
This bean may be used as a *Delegate* using the "Delegate Expression" field as shown in the snippet below.
|
||||
|
||||
```javascript
|
||||
${mqPublishDelegate}
|
||||
```
|
||||
|
||||
You may use it in a **Service Task**.
|
||||
|
||||
|
||||
This method sends a message to an MQ queue.
|
||||
|
||||
It does not wait for a response and will continue after a successful publish of the message to the specified queue. Use `mqSubscribeReplyDelegate` in a subsequent task to handle the response asynchronously.
|
||||
|
||||
If you have more than one MQ communication in a single process, set the `mq_messageName` field on this and the corresponding `mqPublishDelegate` task.
|
||||
|
||||
| Input Type | Name | Java Type | Documentation |
|
||||
| ------------------------ | ------------------------ | ------------------------------------------------ | ---------------------------------- |
|
||||
| BPMN Field | `mq_connectorId` | | An Activiti App Tenant Endpoint ID or Java system property in the format `inteligr8.mq.connectors.{connectorId}.url`. Using system properties support `url`, `username`, and `password`. |
|
||||
| BPMN Field | `mq_queueName` | | The name of an MQ destination (queue or topic). This is the target of the message. If it doesn't exist, it will be created. |
|
||||
| BPMN Field | `mq_messageName` | | [optional] A unique identifier to append to Activiti variables when more than one MQ message publication/subscription is supported by a process. |
|
||||
|
||||
| Result Type | Java Type, Name, or Error Code | Documentation |
|
||||
| ------------------------ | ------------------------------------------------ | -------------------------------- |
|
||||
| Activiti Variable | `mq_correlationId` | The correlationId of the message sent. |
|
||||
| Thrown BPMN Error | `timeout` | The MQ connection timed out connecting or waiting for a message. |
|
||||
| Thrown BPMN Error | `network` | The MQ connection experienced network issues. |
|
||||
| Thrown BPMN Error | `mq` | An unknown MQ issue occurred. |
|
||||
|
||||
*See Also*: [`mqSubscribeReplyDelegate`](bean-mqSubscribeReplyDelegate.md#delegate)
|
||||
*See Also*: [`mqSubscribeDelegate`](bean-mqSubscribeDelegate.md#delegate)
|
||||
|
||||
---
|
||||
|
||||
[Back to Index](index.md)
|
||||
|
||||
Generated by the [Inteligr8](https://inteligr8.com) [Activiti API Doclet](https://bitbucket.org/inteligr8/activiti-api-doclet).
|
||||
|
||||
@@ -0,0 +1,59 @@
|
||||
# API Documentation: MQ Activiti Extension: `mqSubscribeDelegate`
|
||||
|
||||
*Author*: [brian@inteligr8.com](mailto:brian@inteligr8.com)
|
||||
*Since Version*: 1.0
|
||||
|
||||
|
||||
This delegate listens for messages on an MQ queue.
|
||||
|
||||
*See Also*: [`mqPublishDelegate`](bean-mqPublishDelegate.md)
|
||||
*See Also*: [`mqSubscribeReplyDelegate`](bean-mqSubscribeReplyDelegate.md)
|
||||
|
||||
## <a name="delegate"></a> Delegate Expression Uses
|
||||
|
||||
This bean may be used as a *Delegate* using the "Delegate Expression" field as shown in the snippet below.
|
||||
|
||||
```javascript
|
||||
${mqSubscribeDelegate}
|
||||
```
|
||||
|
||||
You may use it in a **Service Task**.
|
||||
|
||||
|
||||
This delegate listens for messages on an MQ queue.
|
||||
|
||||
It does not wait for a response to a specific message put on an MQ queue. That is for the `mqPublishDelegate` and `mqSubscribeReplyDelegate` tasks.
|
||||
|
||||
When used, this task must be the first task after a plain start event in a process. If used in any other way, it will error and the process will fail validation.
|
||||
|
||||
If you have more than one MQ communication in a single process, set the `mq_messageName` field on this task. The resultant variables will then include that message name (e.g. `mq_messageId_{mq_messageName}`).
|
||||
|
||||
TODO map response to variables
|
||||
|
||||
| Input Type | Name | Java Type | Documentation |
|
||||
| ------------------------ | ------------------------ | ------------------------------------------------ | ---------------------------------- |
|
||||
| BPMN Field | `mq_connectorId` | | An Activiti App Tenant Endpoint ID or Java system property in the format `inteligr8.mq.connectors.{connectorId}.url`. Using system properties support `url`, `username`, and `password`. |
|
||||
| BPMN Field | `mq_queueName` | | The name of an MQ destination (queue or topic). This is the target of the message. If it doesn't exist, it will be created. |
|
||||
| BPMN Field | `mq_metadataProcessScope` | | [optional] `true` to set all variables below in the process instance scope; otherwise the variables will be local to the task. |
|
||||
| BPMN Field | `mq_messageName` | | [optional] A unique identifier to append to Activiti variables when more than one MQ message publication/subscription is supported by a process. |
|
||||
|
||||
| Result Type | Java Type, Name, or Error Code | Documentation |
|
||||
| ------------------------ | ------------------------------------------------ | -------------------------------- |
|
||||
| Activiti Variable | `mq_correlationId` | The correlating identifier of the message received. Use to correlate between sent/received messages; like a thread of communication. |
|
||||
| Activiti Variable | `mq_messageId` | The unique message identifer of the message received. |
|
||||
| Activiti Variable | `mq_deliveryTime` | The time the message was delivered; not received. It is of the `java.util.Date` type as supported by Activiti. |
|
||||
| Activiti Variable | `mq_priority` | An integer priority of the message; value depends on MQ protocol. |
|
||||
| Activiti Variable | `mq_replyQueueName` | The name of a queue or topic to use to reply to the received message. The reply message must have the same correlating identifier. |
|
||||
| Thrown BPMN Error | `timeout` | The MQ connection timed out connecting or waiting for a message. |
|
||||
| Thrown BPMN Error | `network` | The MQ connection experienced network issues. |
|
||||
| Thrown BPMN Error | `mq` | An unknown MQ issue occurred. |
|
||||
|
||||
*See Also*: [`mqPublishDelegate`](bean-mqPublishDelegate.md#delegate)
|
||||
*See Also*: [`mqSubscribeReplyDelegate`](bean-mqSubscribeReplyDelegate.md#delegate)
|
||||
|
||||
---
|
||||
|
||||
[Back to Index](index.md)
|
||||
|
||||
Generated by the [Inteligr8](https://inteligr8.com) [Activiti API Doclet](https://bitbucket.org/inteligr8/activiti-api-doclet).
|
||||
|
||||
@@ -0,0 +1,55 @@
|
||||
# API Documentation: MQ Activiti Extension: `mqSubscribeReplyDelegate`
|
||||
|
||||
*Author*: [brian@inteligr8.com](mailto:brian@inteligr8.com)
|
||||
*Since Version*: 1.0
|
||||
|
||||
|
||||
This delegate listens for a reply message on an MQ queue.
|
||||
|
||||
*See Also*: mqPublishDelegate
|
||||
*See Also*: mqSubscribeDelegate
|
||||
|
||||
## <a name="delegate"></a> Delegate Expression Uses
|
||||
|
||||
This bean may be used as a *Delegate* using the "Delegate Expression" field as shown in the snippet below.
|
||||
|
||||
```javascript
|
||||
${mqSubscribeReplyDelegate}
|
||||
```
|
||||
|
||||
You may use it in a **Service Task**.
|
||||
|
||||
|
||||
This method listens for a reply message on an MQ queue.
|
||||
|
||||
It uses the `mq_correlationId` variable to select the corresponding reply message. That variable is automatically set by the `mqPublishDelegate` task. This is meant to be used after `mqPublishDelegate` and not just by itself. If you want to start processes with an MQ subscription see the `mqSubscribeDelegate` task.
|
||||
|
||||
If you have more than one MQ communication in a single process, set the `mq_messageName` field on this and the corresponding `mqPublishDelegate` task.
|
||||
|
||||
TODO map response to variables
|
||||
|
||||
| Input Type | Name | Java Type | Documentation |
|
||||
| ------------------------ | ------------------------ | ------------------------------------------------ | ---------------------------------- |
|
||||
| BPMN Field | `mq_connectorId` | | An Activiti App Tenant Endpoint ID or Java system property in the format `inteligr8.mq.connectors.{connectorId}.url`. Using system properties support `url`, `username`, and `password`. |
|
||||
| BPMN Field | `mq_queueName` | | The name of an MQ destination (queue or topic). This is the target of the message. If it doesn't exist, it will be created. |
|
||||
| BPMN Field | `mq_metadataProcessScope` | | [optional] `true` to set all variables below in the process instance scope; otherwise the variables will be local to the task. |
|
||||
| BPMN Field | `mq_messageName` | | [optional] A unique identifier to append to Activiti variables when more than one MQ message publication/subscription is supported by a process. |
|
||||
| Activiti Variable | `mq_correlationId` | | The correlating identifier of the message to receive. Used to correlate between sent/received messages; like a thread of communication. |
|
||||
|
||||
| Result Type | Java Type, Name, or Error Code | Documentation |
|
||||
| ------------------------ | ------------------------------------------------ | -------------------------------- |
|
||||
| Activiti Variable | `mq_messageId` | The unique message identifer of the message received. |
|
||||
| Activiti Variable | `mq_deliveryTime` | The time the message was delivered; not received. It is of the `java.util.Date` type as supported by Activiti. |
|
||||
| Activiti Variable | `mq_priority` | An integer priority of the message; value depends on MQ protocol. |
|
||||
| Activiti Variable | `mq_replyQueueName` | The name of a queue or topic to use to reply to the received message. The reply message must have the same correlating identifier. |
|
||||
| Thrown BPMN Error | `correlation` | `mq_correlationId` is required. |
|
||||
| Thrown BPMN Error | `timeout` | The MQ connection timed out connecting or waiting for a message. |
|
||||
| Thrown BPMN Error | `network` | The MQ connection experienced network issues. |
|
||||
| Thrown BPMN Error | `mq` | An unknown MQ issue occurred. |
|
||||
|
||||
---
|
||||
|
||||
[Back to Index](index.md)
|
||||
|
||||
Generated by the [Inteligr8](https://inteligr8.com) [Activiti API Doclet](https://bitbucket.org/inteligr8/activiti-api-doclet).
|
||||
|
||||
@@ -0,0 +1,30 @@
|
||||
|
||||
# API Documentation: MQ Activiti Extension
|
||||
|
||||
This file documents the MQ Activiti Extension library. When this library is deployed in Activiti, including Alfresco Process Services, the following API can be utilized.
|
||||
|
||||
Activiti has a set of features that allow a model designer to call these Java-based APIs. These can be from various tasks, listeners, and expressions. The exposure of APIs may differ from method to method. Those details are in this documentation. See the table below for the various integrations between Activiti and these libraries.
|
||||
|
||||
| Activiti Feature | API Notes |
|
||||
| -------------------------------------- | --------- |
|
||||
| Delegate Expression | Any named Spring Bean that implements the `JavaDelegate` interface. |
|
||||
| Expression | Any named Spring Bean and one of its public methods. |
|
||||
| Script | Any named Spring Beans and their public methods. |
|
||||
| Execution Listener Delegate Expression | Any named Spring Bean that implements the `ExecutionListener` interface. |
|
||||
| Execution Listener Expression | Any named Spring Bean and its public method. |
|
||||
| Task Listener Delegate Expression | Any named Spring Bean that implements the `TaskListener` interface. |
|
||||
| Task Listener Expression | Any named Spring Bean and its public method. |
|
||||
|
||||
It is important to note that Activiti expressions use the JUEL language and Activiti scripts use the specified/configured language. Popular configured languages may be JavaScript or Groovy. In any case, the same API notation may be used. It is also worth noting that execution/task listeners may exist on most objects.
|
||||
|
||||
## Delegates
|
||||
|
||||
| Delegate ID | Brief Documentation |
|
||||
| -------------------------------- | ------------------------- |
|
||||
| [`mqPublishDelegate`](bean-mqPublishDelegate.md) | This delegate sends a message to an MQ queue. |
|
||||
| [`mqSubscribeDelegate`](bean-mqSubscribeDelegate.md) | This delegate listens for messages on an MQ queue. |
|
||||
| [`mqSubscribeReplyDelegate`](bean-mqSubscribeReplyDelegate.md) | This delegate listens for a reply message on an MQ queue. |
|
||||
|
||||
---
|
||||
|
||||
Generated by the [Inteligr8](https://inteligr8.com) [Activiti API Doclet](https://bitbucket.org/inteligr8/activiti-api-doclet).
|
||||
Reference in New Issue
Block a user