Tangent API Architecture

This architecture diagram depicts a deployment on Microsoft Azure, utilizing various Azure services within a resource group named "tangent." Here’s a breakdown of the components and their interactions:
API User: Represents external users accessing the API via HTTPS protocol.
Azure Container App: tangent-api-web-service:
Purpose: Handles incoming HTTP requests from API users.
Autoscaling: Configured to scale between 1 to 10 replicas based on HTTP traffic.
Ingress: Enabled (True), allowing external HTTP traffic (on port 443 via HTTPS protocol).
Resources: Allocated 1 CPU core and 2 GiB of memory per replica.
Azure Container App: tangent-api-worker:
Purpose: Processes tasks from the queue.
Autoscaling: Configured to scale between 1 to 20 replicas based on the queue length (queue length = 1).
Ingress: Disabled (False), meaning it doesn't directly receive external traffic.
Resources: Allocated 4 CPU cores and 8 GiB of memory per replica.
Azure Storage Account: tangentstorage:
Storage Container: tangent: Stores persistent data (dataset, configuration, status updates and results).
Queue: tangent: Manages tasks to be processed by the
tangent-api-worker
.
Interactions:
The
tangent-api-web-service
receives requests from API users and interacts with the storage container and the queue within the storage account.The
tangent-api-worker
processes messages from the queue, performing background tasks as required.
This setup ensures scalability and separation of concerns, with the web service handling HTTP traffic and the worker processing background tasks, both scaling independently based on their specific demands.
API interface
The API is secured by Bearer token authentication. Users must include the token in the Authorization
header of their requests. Token is provided in advance with long expiration period. Include this request header in all API requests:
Authorization: Bearer <TOKEN>
In this Swagger page an overview exists of the API endpoints and their functionalities: