VOIP-1283-Add-bin-scheduler-manager - #1153
Closed
pchero wants to merge 12 commits into
Closed
Conversation
- bin-scheduler-manager: Add service skeleton (go.mod, models/schedule, models/execution, internal/config, design/plan docs) - bin-common-handler: Add scheduler queue/service constants, QueueNameRequestAll helper, SchedulerV1 client methods with wire-shape tests
- bin-scheduler-manager: Add cachehandler (redsync lock), dbhandler (claim CAS, reaper, prune) with double-fire and kill-9 tests - bin-dbscheme-manager: Add scheduler_schedules/scheduler_executions tables and platform job seed migrations
- bin-scheduler-manager: Add schedulehandler (CRUD validation), dispatchhandler (tick/claim/dispatch/manual, Forbid overlap, metrics), backuphandler (mysqldump, credential hygiene, retention)
- bin-scheduler-manager: Add listenhandler (RPC API), subscribehandler (customer_deleted), scheduler-manager daemon and scheduler-control CLI
- bin-scheduler-manager: Add Dockerfile (mysql-community-client runtime), k8s manifests (replicas 2), CLAUDE.md/README/docs suite - bin-number-manager: Remove number-renew CronJob manifest (absorbed by scheduler) - monorepo: Register scheduler-manager in CircleCI, queue reference, dependency graph, taxonomy, service counts
- monorepo: Propagate bin-scheduler-manager require/replace directives to all bin-common-handler consumer modules
- bin-scheduler-manager: Add timeout_ms/retry_max validation on create/update; document abandon-not-drain shutdown semantics
- bin-scheduler-manager: Quote and escape the DB password in the mysqldump defaults file (INI special characters) with tests
- bin-scheduler-manager: Create backup dumps 0600; verify MySQL APT key fingerprint over HTTPS and use HTTPS repo; add column-width and target_data JSON validation
- bin-scheduler-manager: Use RPM-GPG-KEY-mysql-2025 (2023 key export expired; same fingerprint); add bounds/JSON validation test coverage for create and update
- bin-scheduler-manager: scheduler-control get resolves name-or-id; reset lag gauge on claim; guard non-positive retention days; document Redis hard dependency; doc fixes
- bin-scheduler-manager: Add test coverage for the non-positive retention guard
|
| GitGuardian id | GitGuardian status | Secret | Commit | Filename | |
|---|---|---|---|---|---|
| 35626146 | Triggered | Generic Password | aec712f | bin-scheduler-manager/pkg/backuphandler/backup_test.go | View secret |
| 35626147 | Triggered | Generic Password | aec712f | bin-scheduler-manager/pkg/backuphandler/backup_test.go | View secret |
🛠 Guidelines to remediate hardcoded secrets
- Understand the implications of revoking this secret by investigating where it is used in your code.
- Replace and store your secrets safely. Learn here the best practices.
- Revoke and rotate these secrets.
- If possible, rewrite git history. Rewriting git history is not a trivial act. You might completely break other contributing developers' workflow and you risk accidentally deleting legitimate data.
To avoid such incidents in the future consider
- following these best practices for managing and storing secrets including API keys and other credentials
- install secret detection on pre-commit to catch secret before it leaves your machine and ease remediation.
🦉 GitGuardian detects secrets in your source code to help developers and security teams secure the modern development process. You are seeing this because you or someone else with access to this repository has authorized GitGuardian to scan your pull request.
Contributor
Author
|
Superseded by the renamed branch/PR (bin-scheduler-manager -> bin-schedule-manager per naming decision). |
pchero
added a commit
that referenced
this pull request
Aug 1, 2026
Add bin-schedule-manager, a platform-internal scheduler service that absorbs external cron jobs into VoIPBin: schedules live in the DB, dispatch is RabbitMQ RPC with a Redis-lock + DB-CAS at-most-once claim, and every run is recorded in an audit trail with per-job Prometheus metrics. The number-renew K8s CronJob is removed; its job is now a seeded schedule that fires on every deployment surface. Replaces PR #1153 after a rename from bin-scheduler-manager to bin-schedule-manager (resource-based naming, incl. DB tables schedule_schedules/schedule_executions). Design and implementation plan are under docs/plans/ (design approved over a 4-round review loop, plan over 3 rounds, code over 8 rounds, rename over 2 rounds). No RST docs changes: Phase 1 has no user-visible API surface (all schedules are platform-owned; customer-facing scheduling is Phase 3). - bin-schedule-manager: New service — schedule/execution models, cron validation (robfig/cron parser), schedule CRUD RPC API with allowlist/bounds validation, tick/claim/dispatch engine (redsync try-once lock, DB CAS + unique execution key in one transaction, Forbid overlap, abandoned-run reaper, single-fire catch-up), manual execute that never consumes the cron slot, in-stack mysqldump backup with credential hygiene (0600 defaults file and dump, HTTPS+fingerprint-pinned MySQL APT key), execution retention pruning, schedule-control admin CLI, Prometheus metrics, K8s manifests (replicas 2), CLAUDE.md/README/docs suite, 260 unit tests incl. double-fire and kill-9 failover proofs - bin-common-handler: Schedule queue/service constants, QueueNameRequestAll enumeration helper with parity test, ScheduleV1 typed client methods with wire-shape tests - bin-dbscheme-manager: schedule_schedules and schedule_executions tables plus seed migration (number-renew enabled, database-backup disabled, execution-retention enabled) - bin-number-manager: Remove the number-renew CronJob manifest and its commented kustomization entry (absorbed by the scheduler) - monorepo: CircleCI registration for the new service, queue reference/dependency graph/taxonomy/prefix-table doc sync, service counts 37 to 38, schedule-manager replace directives propagated to all bin-common-handler consumer modules
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add bin-scheduler-manager, a platform-internal scheduler service that absorbs external cron jobs into VoIPBin: schedules live in the DB, dispatch is RabbitMQ RPC with a Redis-lock + DB-CAS at-most-once claim, and every run is recorded in an audit trail with per-job Prometheus metrics. The number-renew K8s CronJob is removed; its job is now a seeded schedule that fires on every deployment surface. Design and implementation plan are included under docs/plans/ (design approved over a 4-round review loop, plan over 3 rounds, code over 8 rounds). No RST docs changes: Phase 1 has no user-visible API surface (all schedules are platform-owned; customer-facing scheduling is Phase 3).