gitdataai/libs
ZhenYi 8fb2436f22 feat(git): add Redis-backed hook worker with per-repo distributed locking
- pool/worker.rs: single-threaded consumer that BLMPOPs from Redis queues
  sequentially. K8s replicas provide HA — each pod runs one worker.
- pool/redis.rs: RedisConsumer with BLMOVE atomic dequeue, ACK/NAK, and
  retry-with-json support.
- pool/types.rs: HookTask, TaskType, PoolConfig (minimal — no pool metrics).
- sync/lock.rs: Redis SET NX EX per-repo lock to prevent concurrent workers
  from processing the same repo. Lock conflicts are handled by requeueing
  without incrementing retry count.
- hook/mod.rs: HookService.start_worker() spawns the background worker.
- ssh/mod.rs / http/mod.rs: ReceiveSyncService RPUSHes to Redis queue.
  Both run_http and run_ssh call start_worker() to launch the consumer.
- Lock conflicts (GitError::Locked) in the worker are requeued without
  incrementing retry_count so another worker can pick them up.
2026-04-17 12:33:58 +08:00
..
agent feat(service): improve model sync and harden git HTTP/SSH stability 2026-04-17 00:13:40 +08:00
agent-tool-derive init 2026-04-15 09:08:09 +08:00
api feat(frontend): embed SPA assets into app binary at compile time 2026-04-17 12:04:34 +08:00
avatar init 2026-04-15 09:08:09 +08:00
config init 2026-04-15 09:08:09 +08:00
db init 2026-04-15 09:08:09 +08:00
email init 2026-04-15 09:08:09 +08:00
frontend feat(frontend): embed SPA assets into app binary at compile time 2026-04-17 12:04:34 +08:00
git feat(git): add Redis-backed hook worker with per-repo distributed locking 2026-04-17 12:33:58 +08:00
migrate refactor(room): remove NATS, use Redis pub/sub for message queue 2026-04-16 17:24:04 +08:00
models refactor(room): remove NATS, use Redis pub/sub for message queue 2026-04-16 17:24:04 +08:00
queue refactor(room): remove NATS, use Redis pub/sub for message queue 2026-04-16 17:24:04 +08:00
room fix(room): add edit rollback, clean stream channels on room shutdown/idle 2026-04-16 19:28:23 +08:00
rpc init 2026-04-15 09:08:09 +08:00
service feat(service): improve model sync and harden git HTTP/SSH stability 2026-04-17 00:13:40 +08:00
session init 2026-04-15 09:08:09 +08:00
transport init 2026-04-15 09:08:09 +08:00
webhook init 2026-04-15 09:08:09 +08:00