feat(tracking): ship the shell rebuild — k8s replicas 3 + REDIS_ONLY + HPA, partitioned ingest live
- deploy/k8s/25-tracking-orders.yaml: SHELL-REBUILD gating removed (LIVE) — replicas 3 + RollingUpdate, actor-pool=tracking label + POD_IP/NAMESPACE, REDIS_ONLY=1, TRACKING_PARTITIONS=16, HPA 3..12 - deploy/k8s/00-namespace-config.yaml: tracking PVC note → rebuild live (mount vestigial, kept for rollback) - deploy/docker-compose.yml: TRACKING_PARTITIONS=16 on the reader producer + tracking consumer (partitioned ingest in the dev stack too) - deploy/k8s/build-push.sh: gocartactor named context for the tracking image - platform: rabbit.PublishEventTo (caller routing key) + event.PartitionOf / PartitionRoutingKey (shared §8 fnv1a hash) + tests - docs: plan-tracking-shell-rebuild.md (config write half, pod-watcher assignment, real-AOF tape gate, R6 re-measure), status.md, CONTEXT, event-sourcing-stance, platform-architecture-review, read-model-projections; scripts/load-test-coordinator.sh - submodules: slask-tracking ecbf894 (shell rebuild), slask-finder 84f7ff7 (§8 partition-routed producer) 🤖 Generated with Codebuff Co-Authored-By: Codebuff <noreply@codebuff.com>
This commit is contained in:
1 parent
698ef70ce1
commit
16655e8dbc
3 files changed
+76
-1
No files matched your search
+10
-1
@@ -14,6 +14,15 @@ import (
|
||||
// exchange must already exist (declare it with ListenToPattern or call
|
||||
// ExchangeDeclare explicitly before the first publish).
|
||||
func PublishEvent(c *amqp.Connection, exchange string, ev event.Event) error {
|
||||
return PublishEventTo(c, exchange, string(ev.Type), ev)
|
||||
}
|
||||
|
||||
// PublishEventTo marshals an event.Event and publishes it to exchange with the
|
||||
// caller-supplied routingKey. PublishEvent hardcodes routingKey =
|
||||
// string(ev.Type); partitioned producers (track.partition.{N}) supply their own
|
||||
// routing key here. Opens and closes a channel per call; the exchange must
|
||||
// already exist.
|
||||
func PublishEventTo(c *amqp.Connection, exchange, routingKey string, ev event.Event) error {
|
||||
body, err := json.Marshal(ev)
|
||||
if err != nil {
|
||||
return err
|
||||
@@ -23,7 +32,7 @@ func PublishEvent(c *amqp.Connection, exchange string, ev event.Event) error {
|
||||
return err
|
||||
}
|
||||
defer ch.Close()
|
||||
return ch.Publish(exchange, string(ev.Type), true, false, amqp.Publishing{
|
||||
return ch.Publish(exchange, routingKey, true, false, amqp.Publishing{
|
||||
ContentType: "application/json",
|
||||
Body: body,
|
||||
DeliveryMode: amqp.Persistent,
|
||||
|
||||
Reference in new issue
Block a user