Cache Management via EMS

The Orchestrator uses Spring Cache for cache management, you can use it to manage cache contents via EMS queues through a request-response mechanism.

  • EMS request queue: tibco.aff.orchestrator.cache

  • EMS response queue: tibco.aff.orchestrator.cache.reply

Message Structure

Requests sent to the tibco.aff.orchestrator.cache queue must contain the following headers:

  • Originator (Mandatory): Each microservice instance has a unique instance ID. This ID ensures that each microservice instance listens to cache requests specifically meant for it by utilizing the JMS selector feature. Example: instance-12345

  • Operation (mandatory): Specifies the operation to be performed on the cache.

    Supported operations:

    • GET: Retrieves the content of the cache for a specified OrderID and TenantID.

    • CLEAR: Clears the content of the cache for a specified OrderID and TenantID.

    • CLEARALL: Clears the content of all orders in the cache for a specified TenantID.

  • ORDER_ID (Conditional): Specifies the OrderID for operations that target specific orders. It is required for GET and CLEAR operations.

  • TENANTID (Mandatory): Specifies the TenantID for operations. It is required for all operations (GET, CLEAR, and CLEARALL).

Operations

  • GET Operation

    • Description: Retrieve the content of the cache for the specified OrderID and TenantID.

    • Required headers: originator, Operation=GET, ORDER_ID, TENANTID

    • Response: The cached content for the specified OrderID and TenantID is sent to the response queue tibco.aff.orchestrator.cache.reply.

  • CLEAR Operation

    • Description: Clear the content of the cache for the specified OrderID and TenantID.

    • Required headers: originator, Operation=CLEAR, ORDER_ID, TENANTID

    • Response: A confirmation message indicating the cache has been cleared for the specified OrderID and TenantID is sent to the response queue tibco.aff.orchestrator.cache.reply.

  • CLEARALL Operation

    • Description: Clear the content of all orders in the cache for the specified TenantID.

    • Required headers: originator, Operation=CLEARALL, TENANTID

    • Response: A confirmation message indicating the cache has been cleared for all orders for the specified TenantID is sent to the response queue tibco.aff.orchestrator.cache.reply.