diff --git a/submitqueue/orchestrator/controller/batch/batch.go b/submitqueue/orchestrator/controller/batch/batch.go index f6012a748..30e62431e 100644 --- a/submitqueue/orchestrator/controller/batch/batch.go +++ b/submitqueue/orchestrator/controller/batch/batch.go @@ -113,7 +113,7 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er return fmt.Errorf("payload queue %q does not match queue %q of request %s", rid.Queue, request.Queue, request.ID) } - c.logger.Infow("received batch event", + c.logger.Debugw("received batch event", "request_id", request.ID, "queue", request.Queue, "state", string(request.State), @@ -128,7 +128,7 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er // If cancellation races with an attempt already initializing below, speculate re-checks the contained request state before starting work. if entity.IsRequestStateHalted(request.State) { metrics.NamedCounter(c.metricsScope, opName, "skipped_halted", 1, metrics.TagsFromContext(ctx)...) - c.logger.Infow("skipping batch for halted request", + c.logger.Debugw("skipping batch for halted request", "request_id", request.ID, "state", string(request.State), ) @@ -199,13 +199,6 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er return fmt.Errorf("failed to publish batch ID to dependency-analysis topic: %w", err) } - c.logger.Infow("published batch to dependency-analysis topic", - "batch_id", batch.ID, - "request_id", request.ID, - "queue", request.Queue, - "topic_key", topickey.TopicKeyDependencyAnalysis, - ) - return nil // Success - message will be acked } diff --git a/submitqueue/orchestrator/controller/build/build.go b/submitqueue/orchestrator/controller/build/build.go index 2d7015711..5e27a9495 100644 --- a/submitqueue/orchestrator/controller/build/build.go +++ b/submitqueue/orchestrator/controller/build/build.go @@ -299,7 +299,7 @@ func (c *Controller) startPath(ctx context.Context, store orchstorage.Storage, b } metrics.NamedCounter(c.metricsScope, opName, "build_triggered", 1, metrics.TagsFromContext(ctx)...) - c.logger.Infow("triggered build for speculation path", + c.logger.Debugw("triggered build for speculation path", "batch_id", batch.ID, "path_id", entry.ID, "attempt", entry.Attempt, @@ -338,7 +338,7 @@ func (c *Controller) ensureSignal(ctx context.Context, store orchstorage.Storage } metrics.NamedCounter(c.metricsScope, opName, "signal_ensured", 1, metrics.TagsFromContext(ctx)...) - c.logger.Debugw("re-published build signal on redelivery", + c.logger.Infow("re-published build signal on redelivery", "batch_id", batch.ID, "path_id", entry.ID, "attempt", entry.Attempt, diff --git a/submitqueue/orchestrator/controller/buildsignal/buildsignal.go b/submitqueue/orchestrator/controller/buildsignal/buildsignal.go index 7625af091..6c339004e 100644 --- a/submitqueue/orchestrator/controller/buildsignal/buildsignal.go +++ b/submitqueue/orchestrator/controller/buildsignal/buildsignal.go @@ -166,13 +166,6 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er return fmt.Errorf("failed to get build %s: %w", buildID.ID, err) } - c.logger.Debugw("polling build status", - "build_id", build.ID, - "batch_id", build.BatchID, - "attempt", delivery.Attempt(), - "partition_key", msg.PartitionKey, - ) - // Load the batch first: it gives us the queue (needed to build the right // BuildRunner) and lets us short-circuit halted batches before polling. batch, err := store.GetBatchStore().Get(ctx, build.BatchID) @@ -219,7 +212,7 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er ) } else { metrics.NamedCounter(c.metricsScope, opName, "build_cancelled", 1, metrics.TagsFromContext(ctx)...) - c.logger.Infow("requested cancellation of a build nothing wants running", + c.logger.Debugw("requested cancellation of a build nothing wants running", "build_id", build.ID, "batch_id", build.BatchID, "path_id", build.PathID, @@ -264,7 +257,7 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er if status.IsTerminal() { metrics.NamedCounter(c.metricsScope, opName, "terminal", 1, metrics.TagsFromContext(ctx, metrics.NewTag("status", string(status)))...) - c.logger.Infow("build reached terminal status", + c.logger.Debugw("build reached terminal status", "build_id", build.ID, "batch_id", build.BatchID, "status", string(status), @@ -280,6 +273,7 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er c.logger.Debugw("holding for next build status poll", "build_id", build.ID, + "attempt", delivery.Attempt(), "status", string(status), "delay_ms", delayMs, ) diff --git a/submitqueue/orchestrator/controller/cancel/cancel.go b/submitqueue/orchestrator/controller/cancel/cancel.go index 330e6a068..4cc794e6d 100644 --- a/submitqueue/orchestrator/controller/cancel/cancel.go +++ b/submitqueue/orchestrator/controller/cancel/cancel.go @@ -137,7 +137,7 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er return fmt.Errorf("payload queue %q does not match queue %q of request %s", cancelReq.Queue, request.Queue, request.ID) } - c.logger.Infow("received cancel event", + c.logger.Debugw("received cancel event", "request_id", request.ID, "queue", request.Queue, "state", string(request.State), @@ -174,7 +174,7 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er } // Return the first failure so the existing linear error-classification chain remains intact. - // Matches are sorted by ID below, making the selected error deterministic while every failure is still logged and counted. + // FindByRequestID sorts by ID, so the selected error is deterministic. The consumer logs the returned failure, later failures are logged here, and every failure is counted. var firstErr error foundApplicableBatch := false for _, batch := range batches { @@ -183,13 +183,14 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er foundApplicableBatch = true if err := c.cancelBatch(ctx, store, batch); err != nil { metrics.NamedCounter(c.metricsScope, opName, "batch_cancel_errors", 1, metrics.TagsFromContext(ctx)...) - c.logger.Errorw("failed to cancel batch", - "batch_id", batch.ID, - "batch_state", string(batch.State), - "error", err, - ) if firstErr == nil { firstErr = err + } else { + c.logger.Warnw("failed to cancel batch", + "batch_id", batch.ID, + "batch_state", string(batch.State), + "error", err, + ) } } case batch.State == entity.BatchStateLanding: @@ -275,7 +276,7 @@ func (c *Controller) cancelRequest(ctx context.Context, store orchstorage.Storag switch res.Outcome { case corerequest.TerminationOutcomeSuccess, corerequest.TerminationOutcomeAlreadyInTargetState: - c.logger.Infow("request cancelled (not batched)", + c.logger.Debugw("request cancelled (not batched)", "request_id", request.ID, "queue", request.Queue, ) @@ -311,7 +312,7 @@ func (c *Controller) cancelRequest(ctx context.Context, store orchstorage.Storag // intent CAS is skipped and we just re-publish — speculate absorbs the // duplicate as a cheap no-op nudge. func (c *Controller) cancelBatch(ctx context.Context, store orchstorage.Storage, batch entity.Batch) error { - c.logger.Infow("handing batch cancellation off to speculate", + c.logger.Debugw("handing batch cancellation off to speculate", "batch_id", batch.ID, "queue", batch.Queue, "batch_state", string(batch.State), diff --git a/submitqueue/orchestrator/controller/conclude/conclude.go b/submitqueue/orchestrator/controller/conclude/conclude.go index ba7a91a38..99ff68f56 100644 --- a/submitqueue/orchestrator/controller/conclude/conclude.go +++ b/submitqueue/orchestrator/controller/conclude/conclude.go @@ -99,7 +99,7 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er return fmt.Errorf("payload queue %q does not match queue %q of batch %s", bid.Queue, batch.Queue, batch.ID) } - c.logger.Infow("received conclude event", + c.logger.Debugw("received conclude event", "batch_id", batch.ID, "queue", batch.Queue, "state", string(batch.State), diff --git a/submitqueue/orchestrator/controller/dependencyanalysis/dependencyanalysis.go b/submitqueue/orchestrator/controller/dependencyanalysis/dependencyanalysis.go index 7f4dea8af..0d5748642 100644 --- a/submitqueue/orchestrator/controller/dependencyanalysis/dependencyanalysis.go +++ b/submitqueue/orchestrator/controller/dependencyanalysis/dependencyanalysis.go @@ -141,7 +141,7 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er return fmt.Errorf("payload queue %q does not match queue %q of batch %s", bid.Queue, batch.Queue, batch.ID) } - c.logger.Infow("received dependency-analysis event", + c.logger.Debugw("received dependency-analysis event", "batch_id", batch.ID, "queue", batch.Queue, "state", string(batch.State), @@ -177,7 +177,7 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er // Nothing has claimed the request yet, so cancel owned it outright and // has already written its outcome. metrics.NamedCounter(c.metricsScope, opName, "skipped_halted_request", 1, metrics.TagsFromContext(ctx)...) - c.logger.Infow("abandoning batch; contained request is halted", + c.logger.Debugw("abandoning batch; contained request is halted", "batch_id", batch.ID, "request_id", halted, ) @@ -220,7 +220,7 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er RecordValue(float64(len(batch.Contains))) metrics.NamedHistogram(c.metricsScope, "batch_shape", "dependencies", metrics.CountBuckets, metrics.TagsFromContext(ctx)...). RecordValue(float64(len(batch.Dependencies))) - c.logger.Infow("batch created", + c.logger.Debugw("batch created", "batch_id", batch.ID, "queue", batch.Queue, "dependency_count", len(batch.Dependencies), @@ -467,11 +467,6 @@ func (c *Controller) publishToSpeculate(ctx context.Context, batch entity.Batch) metrics.NamedCounter(c.metricsScope, opName, "publish_errors", 1, metrics.TagsFromContext(ctx)...) return fmt.Errorf("failed to publish batch ID to speculate topic: %w", err) } - - c.logger.Infow("published batch to speculate topic", - "batch_id", batch.ID, - "topic_key", topickey.TopicKeySpeculate, - ) return nil } diff --git a/submitqueue/orchestrator/controller/dlq/batch.go b/submitqueue/orchestrator/controller/dlq/batch.go index f1f25bf46..56eadbf6f 100644 --- a/submitqueue/orchestrator/controller/dlq/batch.go +++ b/submitqueue/orchestrator/controller/dlq/batch.go @@ -105,7 +105,7 @@ func (c *batchController) Process(ctx context.Context, delivery consumer.Deliver lastError, failureMeta := failureContext(delivery) dmeta := delivery.Metadata() - c.logger.Warnw("dlq message received", + c.logger.Debugw("dlq message received", "batch_id", bid.ID, "attempt", delivery.Attempt(), "dlq_original_topic", dmeta["dlq.original_topic"], diff --git a/submitqueue/orchestrator/controller/dlq/buildsignal.go b/submitqueue/orchestrator/controller/dlq/buildsignal.go index 97e3480e5..c9b870888 100644 --- a/submitqueue/orchestrator/controller/dlq/buildsignal.go +++ b/submitqueue/orchestrator/controller/dlq/buildsignal.go @@ -99,7 +99,7 @@ func (c *buildSignalController) Process(ctx context.Context, delivery consumer.D lastError, failureMeta := failureContext(delivery) dmeta := delivery.Metadata() - c.logger.Warnw("dlq message received", + c.logger.Debugw("dlq message received", "build_id", buildID.ID, "attempt", delivery.Attempt(), "dlq_original_topic", dmeta["dlq.original_topic"], diff --git a/submitqueue/orchestrator/controller/dlq/dependencyanalysis.go b/submitqueue/orchestrator/controller/dlq/dependencyanalysis.go index 2c1e5ceed..7837365a6 100644 --- a/submitqueue/orchestrator/controller/dlq/dependencyanalysis.go +++ b/submitqueue/orchestrator/controller/dlq/dependencyanalysis.go @@ -113,7 +113,7 @@ func (c *dependencyAnalysisController) Process(ctx context.Context, delivery con lastError, failureMeta := failureContext(delivery) dmeta := delivery.Metadata() - c.logger.Warnw("dlq message received", + c.logger.Debugw("dlq message received", "batch_id", bid.ID, "attempt", delivery.Attempt(), "dlq_original_topic", dmeta["dlq.original_topic"], diff --git a/submitqueue/orchestrator/controller/dlq/landconflictsignal.go b/submitqueue/orchestrator/controller/dlq/landconflictsignal.go index e61679254..d724dd847 100644 --- a/submitqueue/orchestrator/controller/dlq/landconflictsignal.go +++ b/submitqueue/orchestrator/controller/dlq/landconflictsignal.go @@ -90,7 +90,7 @@ func (c *landConflictSignalController) Process(ctx context.Context, delivery con lastError, failureMeta := failureContext(delivery) dmeta := delivery.Metadata() - c.logger.Warnw("dlq message received", + c.logger.Debugw("dlq message received", "request_id", result.Id, "attempt", delivery.Attempt(), "dlq_original_topic", dmeta["dlq.original_topic"], diff --git a/submitqueue/orchestrator/controller/dlq/landsignal.go b/submitqueue/orchestrator/controller/dlq/landsignal.go index fc3f9eaf7..b4da08237 100644 --- a/submitqueue/orchestrator/controller/dlq/landsignal.go +++ b/submitqueue/orchestrator/controller/dlq/landsignal.go @@ -89,7 +89,7 @@ func (c *landSignalController) Process(ctx context.Context, delivery consumer.De lastError, failureMeta := failureContext(delivery) dmeta := delivery.Metadata() - c.logger.Warnw("dlq message received", + c.logger.Debugw("dlq message received", "batch_id", result.Id, "attempt", delivery.Attempt(), "dlq_original_topic", dmeta["dlq.original_topic"], diff --git a/submitqueue/orchestrator/controller/dlq/request.go b/submitqueue/orchestrator/controller/dlq/request.go index 59e5ac579..6e7268736 100644 --- a/submitqueue/orchestrator/controller/dlq/request.go +++ b/submitqueue/orchestrator/controller/dlq/request.go @@ -133,7 +133,7 @@ func (c *requestController) Process(ctx context.Context, delivery consumer.Deliv lastError, failureMeta := failureContext(delivery) dmeta := delivery.Metadata() - c.logger.Warnw("dlq message received", + c.logger.Debugw("dlq message received", "request_id", rid.ID, "attempt", delivery.Attempt(), "dlq_original_topic", dmeta["dlq.original_topic"], diff --git a/submitqueue/orchestrator/controller/dlq/speculate.go b/submitqueue/orchestrator/controller/dlq/speculate.go index 643646d7b..76b6dbc4b 100644 --- a/submitqueue/orchestrator/controller/dlq/speculate.go +++ b/submitqueue/orchestrator/controller/dlq/speculate.go @@ -113,7 +113,7 @@ func (c *speculateController) Process(ctx context.Context, delivery consumer.Del culprits, attribution := c.blame(delivery, bid.ID) failureMeta["dlq.attribution"] = attribution - c.logger.Warnw("dlq message received", + c.logger.Debugw("dlq message received", "batch_id", bid.ID, "queue", bid.Queue, "attempt", delivery.Attempt(), diff --git a/submitqueue/orchestrator/controller/land/land.go b/submitqueue/orchestrator/controller/land/land.go index 6146fd5a1..57b4f1b15 100644 --- a/submitqueue/orchestrator/controller/land/land.go +++ b/submitqueue/orchestrator/controller/land/land.go @@ -127,7 +127,7 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er return fmt.Errorf("payload queue %q does not match queue %q of batch %s", bid.Queue, batch.Queue, batch.ID) } - c.logger.Infow("received land event", + c.logger.Debugw("received land event", "batch_id", batch.ID, "queue", batch.Queue, "state", string(batch.State), @@ -143,7 +143,7 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er // at this stage simply acks. if entity.IsBatchStateHalted(batch.State) { metrics.NamedCounter(c.metricsScope, opName, "skipped_halted", 1, metrics.TagsFromContext(ctx)...) - c.logger.Infow("skipping land for halted batch", + c.logger.Debugw("skipping land for halted batch", "batch_id", batch.ID, "state", string(batch.State), ) @@ -174,12 +174,6 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er return fmt.Errorf("failed to publish to runway merge: %w", err) } - c.logger.Infow("published merge request to Runway", - "batch_id", batch.ID, - "steps", len(req.Steps), - "topic_key", c.runwayTopicKey, - ) - return nil // Success - message will be acked } diff --git a/submitqueue/orchestrator/controller/landconflictsignal/landconflictsignal.go b/submitqueue/orchestrator/controller/landconflictsignal/landconflictsignal.go index 267aa00ca..a3d26bb3b 100644 --- a/submitqueue/orchestrator/controller/landconflictsignal/landconflictsignal.go +++ b/submitqueue/orchestrator/controller/landconflictsignal/landconflictsignal.go @@ -107,7 +107,7 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er return fmt.Errorf("failed to get request %s: %w", result.Id, err) } - c.logger.Infow("received landconflict signal", + c.logger.Debugw("received landconflict signal", "request_id", request.ID, "landable", result.Outcome == runwaypb.Outcome_SUCCEEDED, "attempt", delivery.Attempt(), @@ -121,7 +121,7 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er if entity.IsRequestStateHalted(request.State) { metrics.NamedCounter(c.metricsScope, opName, "skipped_halted", 1, metrics.TagsFromContext(ctx)...) - c.logger.Infow("skipping landconflict signal for halted request", + c.logger.Debugw("skipping landconflict signal for halted request", "request_id", request.ID, "state", string(request.State), ) @@ -130,7 +130,7 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er if result.Outcome != runwaypb.Outcome_SUCCEEDED { metrics.NamedCounter(c.metricsScope, opName, "not_landable", 1, metrics.TagsFromContext(ctx)...) - c.logger.Infow("request not landable", + c.logger.Debugw("request not landable", "request_id", request.ID, "reason", result.Reason, ) @@ -161,11 +161,6 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er return fmt.Errorf("failed to publish to batch: %w", err) } - c.logger.Infow("request validated and published to batch", - "request_id", request.ID, - "topic_key", topickey.TopicKeyBatch, - ) - return nil // Success - message will be acked } diff --git a/submitqueue/orchestrator/controller/landsignal/landsignal.go b/submitqueue/orchestrator/controller/landsignal/landsignal.go index 0b2970ede..81e690bc0 100644 --- a/submitqueue/orchestrator/controller/landsignal/landsignal.go +++ b/submitqueue/orchestrator/controller/landsignal/landsignal.go @@ -109,7 +109,7 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er return fmt.Errorf("failed to get batch %s: %w", result.Id, err) } - c.logger.Infow("received land signal", + c.logger.Debugw("received land signal", "batch_id", batch.ID, "landed", result.Outcome == runwaypb.Outcome_SUCCEEDED, "state", string(batch.State), @@ -155,7 +155,7 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er var newState entity.BatchState if result.Outcome == runwaypb.Outcome_SUCCEEDED { newState = entity.BatchStateSucceeded - c.logger.Infow("landed batch", + c.logger.Debugw("landed batch", "batch_id", batch.ID, "steps", result.Steps, ) diff --git a/submitqueue/orchestrator/controller/ping.go b/submitqueue/orchestrator/controller/ping.go index 66afa9459..ff5297a69 100644 --- a/submitqueue/orchestrator/controller/ping.go +++ b/submitqueue/orchestrator/controller/ping.go @@ -56,7 +56,7 @@ func (c *PingController) Ping(ctx context.Context, req *pb.PingRequest) (resp *p hostname, _ := os.Hostname() - c.logger.Info("ping request received", + c.logger.Debug("ping request received", zap.String("message", req.Message), zap.Bool("is_echo", isEcho), zap.String("hostname", hostname), diff --git a/submitqueue/orchestrator/controller/speculate/finalize.go b/submitqueue/orchestrator/controller/speculate/finalize.go index 777f9d5d5..a1889d8a0 100644 --- a/submitqueue/orchestrator/controller/speculate/finalize.go +++ b/submitqueue/orchestrator/controller/speculate/finalize.go @@ -220,7 +220,7 @@ func (c *Controller) finalizeCancellations(ctx context.Context, snap *snapshot, // read folded that in — so a path still reading as unstopped really is. if exists && !allPathsStopped(set) { metrics.NamedCounter(c.metricsScope, opName, "cancel_awaiting_paths", 1, metrics.TagsFromContext(ctx)...) - c.logger.Infow("cancelling batch; waiting for its builds to stop", + c.logger.Debugw("cancelling batch; waiting for its builds to stop", "batch_id", batch.ID, "queue", batch.Queue, ) @@ -346,7 +346,7 @@ func (c *Controller) applyOutcome(ctx context.Context, store orchstorage.Storage } metrics.NamedCounter(c.metricsScope, opName, "outcome", 1, metrics.TagsFromContext(ctx, metrics.NewTag("outcome", string(decision)))...) - c.logger.Infow("batch outcome", + c.logger.Debugw("batch outcome", "batch_id", batch.ID, "queue", batch.Queue, "outcome", string(decision), diff --git a/submitqueue/orchestrator/controller/speculate/speculate.go b/submitqueue/orchestrator/controller/speculate/speculate.go index f6d42a452..68aa5ebfd 100644 --- a/submitqueue/orchestrator/controller/speculate/speculate.go +++ b/submitqueue/orchestrator/controller/speculate/speculate.go @@ -185,7 +185,7 @@ func (c *Controller) admit(ctx context.Context, store orchstorage.Storage, batch } metrics.NamedCounter(c.metricsScope, opName, "admitted", 1, metrics.TagsFromContext(ctx)...) - c.logger.Infow("admitted batch to speculation", + c.logger.Debugw("admitted batch to speculation", "batch_id", updated.ID, "queue", updated.Queue, "dependencies", updated.Dependencies, diff --git a/submitqueue/orchestrator/controller/start/start.go b/submitqueue/orchestrator/controller/start/start.go index 85c415bf9..1266e2b31 100644 --- a/submitqueue/orchestrator/controller/start/start.go +++ b/submitqueue/orchestrator/controller/start/start.go @@ -104,7 +104,7 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er Version: 1, } - c.logger.Infow("received land request event", + c.logger.Debugw("received land request event", "request_id", request.ID, "queue", request.Queue, "state", string(request.State), @@ -135,11 +135,6 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er return fmt.Errorf("failed to publish to validate: %w", err) } - c.logger.Infow("published request to validate", - "request_id", request.ID, - "topic_key", topickey.TopicKeyValidate, - ) - return nil } diff --git a/submitqueue/orchestrator/controller/validate/validate.go b/submitqueue/orchestrator/controller/validate/validate.go index 808073c35..63633053e 100644 --- a/submitqueue/orchestrator/controller/validate/validate.go +++ b/submitqueue/orchestrator/controller/validate/validate.go @@ -124,7 +124,7 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er return fmt.Errorf("payload queue %q does not match queue %q of request %s", rid.Queue, request.Queue, request.ID) } - c.logger.Infow("received validate event", + c.logger.Debugw("received validate event", "request_id", request.ID, "queue", request.Queue, "state", string(request.State), @@ -141,7 +141,7 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er // Cancellation intent halts forward progress even before the terminal outcome. if entity.IsRequestStateHalted(request.State) { coremetrics.NamedCounter(c.metricsScope, "process", "skipped_halted", 1, coremetrics.TagsFromContext(ctx)...) - c.logger.Infow("skipping validate for halted request", + c.logger.Debugw("skipping validate for halted request", "request_id", request.ID, "state", string(request.State), ) @@ -186,7 +186,7 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er return fmt.Errorf("failed to fetch change information for request %s: %w", request.ID, err) } - c.logger.Infow("fetched change information", + c.logger.Debugw("fetched change information", "request_id", request.ID, "change_count", len(changeInfos), "total_files", totalFiles(changeInfos), @@ -212,7 +212,7 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er return fmt.Errorf("failed to validate request %s: %w", request.ID, err) } coremetrics.NamedCounter(c.metricsScope, "process", "custom_validation_failures", 1, coremetrics.TagsFromContext(ctx)...) - c.logger.Infow("custom validation rejected request", + c.logger.Debugw("custom validation rejected request", "request_id", request.ID, "queue", request.Queue, "error", err.Error(), @@ -253,11 +253,6 @@ func (c *Controller) Process(ctx context.Context, delivery consumer.Delivery) er return fmt.Errorf("failed to publish to runway merge-conflict-check: %w", err) } - c.logger.Infow("published merge conflict check to Runway", - "request_id", request.ID, - "topic_key", c.runwayTopicKey, - ) - return nil // Success - message will be acked }