D
Docs
Documentation Background Workers

We use Trigger.dev to manage background workers, it is a powerful tool that allows you to manage background workers in a simple way with javascript. We've decided to opt-out of the famous Redis based background workers and go with Trigger.dev as this is a more modern and powerful tool and it's easier to manage.

Key Features

1. TypeScript Support

  • Full TypeScript support out of the box
  • Type-safe job definitions and payloads
  • Better developer experience with autocomplete and type checking

2. Developer Experience

  • Local development environment with hot reloading
  • Built-in dashboard for monitoring jobs
  • Detailed logging and error tracking
  • Easy debugging with step-by-step execution view

3. Reliability

  • Automatic retries with configurable backoff strategies
  • Dead letter queues for failed jobs
  • Job deduplication to prevent duplicate processing
  • Idempotency support

4. Scalability

  • Distributed job processing
  • Horizontal scaling capabilities
  • Built-in rate limiting
  • Support for multiple environments (dev, staging, prod)

5. Integration Capabilities

  • Webhook support for external integrations
  • Built-in integrations with popular services
  • Custom integration support via HTTP clients
  • Event-driven architecture support

Key Benefits

1. Simplified Development

  • No need to manage Redis or other infrastructure
  • Declarative job definitions
  • Built-in error handling and retries
  • Reduced boilerplate code

2. Cost Efficiency

  • Pay-as-you-go pricing model
  • No need to maintain additional infrastructure
  • Reduced operational overhead
  • Optimized resource utilization

3. Monitoring and Observability

  • Real-time job status monitoring
  • Detailed execution logs
  • Performance metrics and analytics
  • Error tracking and debugging tools

4. Security

  • Secure job execution environment
  • API key authentication
  • Environment variable management
  • Role-based access control

5. Maintenance

  • Automatic updates and improvements
  • Managed infrastructure
  • Regular security patches
  • Technical support and documentation