HTTP API for managing long-running I/O bound tasks
- In-memory task storage
- Asynchronous task processing
- Thread-safe operations
- Automatic memory cleanup when tasks are deleted
In root directory run command for build and execute. build is default goal.
make
make runTo run the tests, run this command.
make testPOST /tasks- creates new task. Returns 202 Accepted and JSON struct
{
"id": 1,
"created_at": "2025-06-21T15:04:05Z",
"status": "pending"
}
GET /tasks/{id}- returns information on a specific taskid— numeric identifier.created_at— date/time of creation.status— one of: pending, running, completed, canceled, failed.result— string with result (present if status == completed).error— error text (if status == failed)
{
"id": 1,
"created_at": "2025-06-21T15:04:05Z",
"status": "completed",
"result": "example"
}DELETE /tasks/{id}- delete/cancel task200 OK- if success404 Not Found- if task not found