HSG-MCS-HS21_tapas/TAPAS-Final/doc/architecture/decisions/0008-executor-base-library.md
2021-12-23 07:15:07 +00:00

1.8 KiB
Raw Permalink Blame History

8. Executor base library

Date: 2021-11-21

Status

Accepted

Context

According to the project requirements, Executors can be developed by other teams within the organisation. Executors all use the same logic to communicate with other services. This means that their code base is near identical except for the code that implements their specific task execution. The code that implements the executor's shared logic can either be implemented by a shared library, or replicated across all executors.

Decision

We will implement a shared library for common Executor functionality.

All executors use the same logic to communicate with other services, any change to this logic would have to be made for every executor. Having this shared logic in a separate library makes it easy to change the common logic at one place. The code sharing happens at compile time, which reduces the chance of runtime errors, compared to other code sharing approaches.

Additionally, if other teams need to create executors, they can just reference the executor-base library and implement the actual execution part. Therefore, they dont need to worry about the connection implementations to the TAPAS system.

Consequences

Using a shared library will increase the complexity of the executors.

Changes in the common code will most likely require multiple services to be redeployed. However, those services would most likely have to have been changed individually and redeployed anyways.

Another consequence is that versioning becomes more complicated.

Lastly, we have to make sure that we don't become over reliant on everyone using this library to communicate with the TAPAS system. Future IoT Executors might want to use a more lightweight way to communicate, so we will have to be aware of this.