Skip to content

feat(cron): IHostedService cron scheduler + /cron commands#3

Open
lucasven wants to merge 1 commit intoHanake0:mainfrom
lucasven:feat/cron-service
Open

feat(cron): IHostedService cron scheduler + /cron commands#3
lucasven wants to merge 1 commit intoHanake0:mainfrom
lucasven:feat/cron-service

Conversation

@lucasven
Copy link
Copy Markdown

What

Background cron scheduler as IHostedService with PostgreSQL-backed job storage
and chat commands for management.

Features

  • IHostedService: Background service with cron expression support
  • PostgreSQL storage: Jobs table with status, schedule, last run
  • Deterministic + non-deterministic: Static schedules + post-cron LLM hooks
  • Chat commands: /cron add, /cron list, /cron remove

Files

  • Lis.Core/Scheduling/ — CronService, CronJob entity, repository
  • Lis.Core/Commands/ — /cron command handler
  • Database migration for cron_jobs table
  • Unit tests for scheduler, commands, and job management

- CronJobEntity with PostgreSQL migration
- IHostedService-based CronService (30s timer, Cronos parsing)
- ICronHandler interface for extensible job handlers
- CronPlugin (cron_add, cron_list, cron_remove) for AI tool use
- /cron command (add, list, remove) for chat commands
- 103 tests passing (30 new)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant