Skip to main content

Workers

Most Processes can be implemented by using Unmeshed's built-in Steps. These Steps run directly on the Unmeshed Engine and are designed for simplicity, performance and scalability. There are cases, however, when it may be more desirable to run workloads outside of Unmeshed. Some reasons could include:

  1. When Unmeshed does not have access to data due to organization policies
  2. When business logic already exists elsewhere but is not available via APIs
  3. When built-in Steps do not provide a viable solution

To support these cases, Unmeshed uses the concept of Workers. Workers are external clients that connect to the Unmeshed server and poll for work that needs to be executed. As soon as work is available, Unmeshed issues the work to the Worker by sending the parameters provided by the relevant Step, and manages execution of the Worker code in the same way it manages any other tasks. Put differently, even though the code isn't directly executed on Unmeshed, the platform still ensures a timely execution and reschedules the work should any issues arise.

Centered
Fast Real Time Orchestration

Video Overview: Workers or Custom Code in Unmeshed

Github Codebase for Java SDK Example

Github Codebase for Java SDK Example

What language can I write my worker code in?

We have a simple API based integration model and you can write your workers in any language of your choice. You can use our SDKs to simplify this. Currently we have support for Java SDK. Python and TypeScript(JS) SDKs are in the works. If you have another language you will prefer to use, let us know and we will have it ready in no time.

Our SDKs are lightweight and is strictly intended to manage token auth and efficient retrieval of work.

Where can I find the SDKs?

Connect with our team and we will provide you the coordinates to pull our SDKs.

Can the workers scale?

In a single node cluster we have demonstrated running up to 5000 workers completing per second include simulated worker delays. Our servers can handle any scale you require. Once you cross the capacity of a single node, you can add on more nodes to achieve more scale.

Example

Here's an example of the Java based worker

{
"transferAmount": 1000,
"sourceAccount": "acc-10001",
"destinationAccount": "acc-20002"
}