Deploy background workers.
Keep background work running without babysitting the process. It runs alongside the rest of your app with access to the same data and configuration.
AI agent? Start with llms.txt.
What you can keep running
Background workers fit code that waits continuously for more work and does not need an HTTP URL or schedule.
Queue consumers.
Pull work from SQS, Redis, or RabbitMQ and process jobs as they arrive.
Pollers and data syncs.
Watch an external API, reconcile state, or keep two systems in sync.
Bots and event processors.
Run notification dispatchers, chat bots, or processors for Kafka and Kinesis streams.
From code to an always on worker
Use a normal long running process. We keep it available while you keep ownership of how it receives and processes work.
Step 01
Keep the worker code you already use.
No Tokay SDK is required. The queue client, polling loop, and shutdown behavior stay in the application.
Step 02
Connect it to the rest of the app.
Put related Services in one Project so the worker can use the same databases, Config, and Secrets.
Step 03
Deploy it as its own Service.
The worker gets its own deployment history and logs, so it can be updated or diagnosed without replacing the web app.
Step 04
Replace it cleanly.
During an update, we signal the current worker before starting its replacement so shutdown code has time to finish active work.
Just write your worker
Loop, wait for work, and log what matters. We handle the process around it.
Node.js worker loop
const sleep = (ms) => new Promise((resolve) => setTimeout(resolve, ms));
async function run() {
while (true) {
console.log('checking queue');
// Pull a job from SQS, Redis, RabbitMQ, etc.
await sleep(30000);
}
}
run().catch((err) => {
console.error(err);
process.exit(1);
});
Python poller
import time
def sync_once():
print('syncing upstream data')
# Call an API, write to your database, repeat.
while True:
sync_once()
time.sleep(30)
Go worker loop
package main
import (
"log"
"time"
)
func main() {
for {
log.Println("processing next event")
// Read from Kafka, Kinesis, or a queue.
time.Sleep(30 * time.Second)
}
}
What Tokay handles
A process that stays available.
We start the worker on deploy, restart it after a crash, and bring it back after the server reboots.
Failure evidence and recovery alerts.
Standard output and error stay available with the incident timeline, and we email when the worker goes down and recovers.
Independent operations.
Pause, diagnose, and redeploy the worker without replacing the web app that shares its Project.
Read the background workers doc for restarts, logs, and clean swaps
Run your worker. Skip the babysitting.
Push code. We keep it running. That's the whole deal.