-
Notifications
You must be signed in to change notification settings - Fork 3.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
131396: log/eventpb: add job ID to all changefeed structured log events r=kyle-a-wong,rharding6373 a=andyyang890 **log/eventpb: move changefeed structured log events to separate category** Release note: None ---- **log/eventpb: add job ID to all changefeed structured log events** Release note (ops change): `changefeed_failed` and `create_changefeed` log events now include a `JobId` field for enterprise changefeeds. ---- Informs #121697 Co-authored-by: Andy Yang <[email protected]>
- Loading branch information
Showing
11 changed files
with
174 additions
and
137 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
// Copyright 2024 The Cockroach Authors. | ||
// | ||
// Use of this software is governed by the Business Source License | ||
// included in the file licenses/BSL.txt. | ||
// | ||
// As of the Change Date specified in that file, in accordance with | ||
// the Business Source License, use of this software will be governed | ||
// by the Apache License, Version 2.0, included in the file | ||
// licenses/APL.txt. | ||
|
||
syntax = "proto3"; | ||
package cockroach.util.log.eventpb; | ||
option go_package = "github.com/cockroachdb/cockroach/pkg/util/log/eventpb"; | ||
|
||
import "gogoproto/gogo.proto"; | ||
import "util/log/eventpb/events.proto"; | ||
import "util/log/logpb/event.proto"; | ||
|
||
// Category: Changefeed telemetry events | ||
// Channel: TELEMETRY | ||
// | ||
// Events in this category pertain to changefeed usage and metrics. | ||
|
||
// CreateChangefeed is an event for any CREATE CHANGEFEED query that | ||
// successfully starts running. Failed CREATE statements will show up as | ||
// ChangefeedFailed events. | ||
message CreateChangefeed { | ||
CommonChangefeedEventDetails common = 1 [(gogoproto.nullable) = false, (gogoproto.jsontag) = "", (gogoproto.embed) = true]; | ||
|
||
// Flag representing whether the changefeed is using CDC queries. | ||
bool transformation = 2 [(gogoproto.jsontag) = ",omitempty", (gogoproto.moretags) = "redact:\"nonsensitive\""]; | ||
} | ||
|
||
// ChangefeedFailed is an event for any changefeed failure since the plan hook | ||
// was triggered. | ||
message ChangefeedFailed { | ||
CommonChangefeedEventDetails common = 1 [(gogoproto.nullable) = false, (gogoproto.jsontag) = "", (gogoproto.embed) = true]; | ||
|
||
// The reason / environment with which the changefeed failed | ||
// (ex: connection_closed, changefeed_behind). | ||
string failure_type = 2 [(gogoproto.jsontag) = ",omitempty", (gogoproto.moretags) = "redact:\"nonsensitive\""]; | ||
} | ||
|
||
// ChangefeedEmittedBytes is an event representing the bytes emitted by a changefeed over an interval. | ||
message ChangefeedEmittedBytes { | ||
CommonChangefeedEventDetails common = 1 [(gogoproto.nullable) = false, (gogoproto.jsontag) = "", (gogoproto.embed) = true]; | ||
|
||
reserved 2; | ||
|
||
// The number of bytes emitted. | ||
int64 emitted_bytes = 3 [(gogoproto.jsontag) = ",omitempty", (gogoproto.moretags) = "redact:\"nonsensitive\""]; | ||
|
||
// The number of messages emitted. | ||
int64 emitted_messages = 6 [(gogoproto.jsontag) = ",omitempty", (gogoproto.moretags) = "redact:\"nonsensitive\""]; | ||
|
||
// The time period in nanoseconds between emitting telemetry events of this type (per-aggregator). | ||
int64 logging_interval = 4 [(gogoproto.jsontag) = ",omitempty", (gogoproto.moretags) = "redact:\"nonsensitive\""]; | ||
|
||
// Flag to indicate that the changefeed is closing. | ||
bool closing = 5 [(gogoproto.jsontag) = ",omitempty", (gogoproto.moretags) = "redact:\"nonsensitive\""]; | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains 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
Oops, something went wrong.