Skip to content

Commit 8527495

Browse files
committed
split changesets
1 parent e22c248 commit 8527495

File tree

4 files changed

+204
-57
lines changed

4 files changed

+204
-57
lines changed
Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
---
2+
"@vorsteh-queue/adapter-drizzle": minor
3+
---
4+
5+
# 🚀 Initial Release - Drizzle ORM Adapter
6+
7+
Production-ready database adapter supporting PostgreSQL and MariaDB/MySQL via Drizzle ORM.
8+
9+
## 🗄️ Database Support
10+
11+
### PostgreSQL
12+
- **PostgreSQL 12+** with SKIP LOCKED support for concurrent processing
13+
- **Multiple drivers**: node-postgres, postgres.js, PGlite
14+
- **Full feature support**: JSONB payloads, UUID primary keys, timezone-aware timestamps
15+
- **Connection pooling** and transaction support
16+
17+
### MariaDB/MySQL
18+
- **MariaDB 10.6+** and **MySQL 8.0+** with SKIP LOCKED functionality
19+
- **mysql2 driver** with promise support and connection pooling
20+
- **JSON payloads** with proper serialization/deserialization
21+
- **UUID compatibility** using VARCHAR(36) with MySQL UUID() function
22+
23+
## ⚡ Performance Features
24+
25+
- **SKIP LOCKED** queries for high-concurrency job processing without lock contention
26+
- **Optimized indexes** on queue_name, status, priority, and process_at columns
27+
- **Efficient job retrieval** with priority-based ordering and creation time fallback
28+
- **Batch operations** for job cleanup and maintenance
29+
30+
## 🔧 Schema Management
31+
32+
- **Exported schemas** - `postgresSchema` and `mariadbSchema` for easy integration
33+
- **Drizzle Kit support** - Generate and run migrations with your existing schema
34+
- **Type-safe queries** - Full TypeScript support with Drizzle's query builder
35+
- **Flexible integration** - Works with existing Drizzle setups
36+
37+
## 📦 Easy Integration
38+
39+
```typescript
40+
// PostgreSQL
41+
import { PostgresQueueAdapter, postgresSchema } from "@vorsteh-queue/adapter-drizzle"
42+
const db = drizzle(pool, { schema: postgresSchema })
43+
const adapter = new PostgresQueueAdapter(db, "my-queue")
44+
45+
// MariaDB/MySQL
46+
import { MariaDBQueueAdapter, mariadbSchema } from "@vorsteh-queue/adapter-drizzle"
47+
const db = drizzle(connection, { schema: mariadbSchema })
48+
const adapter = new MariaDBQueueAdapter(db, "my-queue")
49+
```
50+
51+
## 🛡️ Production Ready
52+
53+
- **Connection pooling** support for high-throughput applications
54+
- **Transaction support** for atomic job operations
55+
- **Error handling** with proper database-specific error types
56+
- **Schema validation** and type safety throughout

.changeset/core-initial-release.md

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
---
2+
"@vorsteh-queue/core": minor
3+
---
4+
5+
# 🚀 Initial Release - Core Queue Engine
6+
7+
The foundational package providing the core queue functionality and interfaces.
8+
9+
## ✨ Features
10+
11+
- **Type-safe job processing** with full TypeScript support and generic job payloads
12+
- **Priority queue system** with numeric priority (lower = higher priority)
13+
- **Delayed job scheduling** for future execution with precise timing
14+
- **Recurring jobs** with cron expressions and interval-based repetition
15+
- **Timezone-aware scheduling** with automatic DST handling
16+
- **Real-time progress tracking** for long-running jobs (0-100%)
17+
- **Comprehensive event system** for monitoring job lifecycle
18+
- **Graceful shutdown** with clean job processing termination
19+
20+
## 🎛️ Queue Configuration
21+
22+
- **Flexible job cleanup** - `removeOnComplete`/`removeOnFail` support boolean or number
23+
- **Configurable concurrency** - Process multiple jobs simultaneously
24+
- **Retry logic** with exponential backoff and max attempts
25+
- **Job timeouts** and comprehensive error handling
26+
- **Queue statistics** and health monitoring
27+
28+
## 📊 Event System
29+
30+
- **Job lifecycle events**: `job:added`, `job:processing`, `job:completed`, `job:failed`, `job:retried`, `job:progress`
31+
- **Queue events**: `queue:paused`, `queue:resumed`, `queue:stopped`, `queue:error`
32+
- **Type-safe event handlers** with proper TypeScript support
33+
34+
## 🌍 Timezone Support
35+
36+
- Schedule jobs in any IANA timezone with automatic DST transitions
37+
- Complex cron expressions with timezone awareness
38+
- UTC-first storage with timezone-aware calculations
39+
- Reliable cross-timezone job scheduling
40+
41+
## 🔌 Adapter Pattern
42+
43+
- **Pluggable storage backends** - Easy to add new database adapters
44+
- **Consistent interface** - Same API across all storage implementations
45+
- **Built-in memory adapter** - Perfect for testing and development
46+
- **Transaction support** - Atomic job operations where supported
Lines changed: 72 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,72 @@
1+
---
2+
"create-vorsteh-queue": minor
3+
---
4+
5+
# 🚀 Initial Release - Project Scaffolding CLI
6+
7+
Interactive CLI tool for creating new Vorsteh Queue projects with zero configuration.
8+
9+
## ✨ Features
10+
11+
- **Interactive prompts** with beautiful UI powered by @clack/prompts
12+
- **Dynamic template discovery** - Automatically fetches available templates from GitHub
13+
- **Multiple package managers** - Support for npm, pnpm, yarn, and bun
14+
- **CLI flags** for automation and scripting
15+
- **Quiet mode** for CI/CD environments
16+
17+
## 🎯 Usage Options
18+
19+
### Interactive Mode
20+
```bash
21+
npx create-vorsteh-queue
22+
# Prompts for project name, template, and package manager
23+
```
24+
25+
### Direct Mode
26+
```bash
27+
npx create-vorsteh-queue my-app --template=drizzle-pglite --package-manager=pnpm
28+
# Fully automated project creation
29+
```
30+
31+
### CLI Flags
32+
- `--template=<name>` or `-t=<name>` - Choose template
33+
- `--package-manager=<pm>` or `-pm=<pm>` - Package manager (npm/pnpm/yarn/bun)
34+
- `--quiet` or `-q` - Minimal output for automation
35+
36+
## 📦 Available Templates
37+
38+
Templates are **dynamically discovered** from the repository:
39+
40+
- **drizzle-postgres** - Production-ready PostgreSQL setup with postgres.js
41+
- **drizzle-pg** - Simple PostgreSQL setup with node-postgres
42+
- **drizzle-pglite** - Embedded PostgreSQL with zero setup required
43+
- **progress-tracking** - Real-time job progress monitoring example
44+
- **event-system** - Comprehensive event monitoring and statistics
45+
46+
## 🔧 Smart Features
47+
48+
- **Latest versions** - Automatically fetches current package versions from npm registry
49+
- **Workspace replacement** - Converts workspace dependencies to npm versions
50+
- **Template validation** - Ensures selected templates exist and are valid
51+
- **Package manager detection** - Validates and uses specified package manager
52+
- **Error handling** - Graceful fallbacks and helpful error messages
53+
54+
## 🤖 Automation Ready
55+
56+
Perfect for CI/CD pipelines and scripting:
57+
58+
```bash
59+
# Silent project creation
60+
npx create-vorsteh-queue worker-service \
61+
--template=drizzle-postgres \
62+
--package-manager=pnpm \
63+
--quiet
64+
```
65+
66+
## 🎨 Developer Experience
67+
68+
- **Colorful output** with picocolors for enhanced readability
69+
- **Progress indicators** with spinners for long-running operations
70+
- **Helpful links** to documentation and examples
71+
- **Validation** with clear error messages and suggestions
72+
- **Cross-platform** support for Windows, macOS, and Linux

.changeset/green-houses-think.md

Lines changed: 30 additions & 57 deletions
Original file line numberDiff line numberDiff line change
@@ -1,74 +1,47 @@
11
---
2-
"@vorsteh-queue/adapter-drizzle": minor
3-
"@vorsteh-queue/core": minor
4-
"create-vorsteh-queue": minor
52
---
63

7-
# 🚀 Initial Release of Vorsteh Queue
4+
# 🚀 Vorsteh Queue - Initial Release
85

9-
A TypeScript-first job queue system with multiple database adapters, built for reliability and developer experience.
6+
A powerful, TypeScript-first job queue system designed for modern applications.
107

11-
## ✨ Core Features
8+
## 📦 What's Included
129

13-
- **Type-safe job processing** with full TypeScript support and generic job payloads
14-
- **Multiple database adapters** supporting Drizzle ORM, Prisma, and in-memory implementations
15-
- **Priority queue system** with numeric priority (lower = higher priority)
16-
- **Delayed job scheduling** for future execution
17-
- **Recurring jobs** with cron expressions and interval-based repetition
18-
- **Timezone-aware scheduling** with DST handling powered by date-fns
19-
- **Real-time progress tracking** for long-running jobs
20-
- **Comprehensive event system** for monitoring job lifecycle
21-
- **Graceful shutdown** with clean job processing termination
10+
This release introduces three core packages:
2211

23-
## 🗄️ Database Adapters
12+
- **@vorsteh-queue/core** - The foundational queue engine with type-safe job processing
13+
- **@vorsteh-queue/adapter-drizzle** - Production-ready PostgreSQL and MariaDB/MySQL adapter
14+
- **create-vorsteh-queue** - Interactive CLI for scaffolding new projects
2415

25-
- **@vorsteh-queue/adapter-drizzle** - PostgreSQL support via Drizzle ORM (node-postgres, postgres.js, PGlite)
26-
- **@vorsteh-queue/adapter-prisma** - Multi-database support via Prisma (PostgreSQL, MySQL, SQLite, MongoDB)
27-
- **Built-in memory adapter** - For testing and development
16+
## 🎯 Key Highlights
2817

29-
## 🎛️ Advanced Configuration
18+
- **Zero-config setup** with the CLI tool - `npx create-vorsteh-queue`
19+
- **Production-ready** database adapters with connection pooling and SKIP LOCKED
20+
- **Type-safe throughout** with full TypeScript support and generic job payloads
21+
- **Timezone-aware scheduling** with automatic DST handling
22+
- **Real-time progress tracking** and comprehensive event system
23+
- **Multiple examples** covering basic usage to production deployment
3024

31-
- **Flexible job cleanup** - `removeOnComplete`/`removeOnFail` support boolean (immediate/never) or number (keep N jobs)
32-
- **Configurable concurrency** - Process multiple jobs simultaneously
33-
- **Retry logic** with exponential backoff
34-
- **Job timeouts** and error handling
35-
- **Queue statistics** and monitoring
25+
## 🚀 Quick Start
3626

37-
## 🌍 Timezone Support
27+
```bash
28+
# Create a new project
29+
npx create-vorsteh-queue my-queue-app
3830

39-
- Schedule jobs in any IANA timezone
40-
- Automatic DST transition handling
41-
- Complex cron expressions with timezone awareness
42-
- UTC storage with timezone-aware calculations
43-
44-
## 📊 Progress & Events
45-
46-
- Real-time job progress updates (0-100%)
47-
- Complete job lifecycle events (added, processing, completed, failed, retried)
48-
- Queue-level events (paused, resumed, stopped, error)
49-
- Built-in statistics tracking
50-
51-
## 📚 Examples & Documentation
52-
53-
- **Basic usage examples** with Drizzle + node-postgres/postgres.js
54-
- **Progress tracking demo** showing real-time updates
55-
- **Event system showcase** with comprehensive monitoring
56-
- **PM2 production deployment** with multiple specialized workers
57-
- **Complete TypeScript examples** with proper typing
31+
# Choose from multiple templates:
32+
# - drizzle-postgres (Production ready)
33+
# - drizzle-pglite (Zero setup)
34+
# - progress-tracking (Real-time updates)
35+
# - event-system (Comprehensive monitoring)
36+
```
5837

5938
## 🛠️ Developer Experience
6039

61-
- Full TypeScript support with strict typing
62-
- Comprehensive test coverage
63-
- ESLint and Prettier configuration
64-
- Multiple runnable examples
65-
- Production-ready PM2 configuration
40+
Built with developer experience in mind:
6641

67-
## 🎯 Production Ready
42+
- **Interactive CLI** with beautiful prompts and dynamic template discovery
43+
- **Comprehensive examples** with runnable code for every feature
44+
- **Production deployment** guides with PM2 and Docker
45+
- **Full documentation** with TypeScript examples throughout
6846

69-
- Database persistence with connection pooling
70-
- Process management with PM2
71-
- Memory limits and auto-restart
72-
- Log rotation and monitoring
73-
- Graceful shutdown handling
74-
- Health checks and error recovery
47+
See individual package changesets for detailed feature lists and technical specifications.

0 commit comments

Comments
 (0)