-
Notifications
You must be signed in to change notification settings - Fork 298
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chore: router delivery req-res debug logs #4737
base: chore.rt-delivery-resp-log
Are you sure you want to change the base?
chore: router delivery req-res debug logs #4737
Conversation
* chore(deps): bump the go-deps group across 1 directory with 10 updates Bumps the go-deps group with 9 updates in the / directory: | Package | From | To | | --- | --- | --- | | [github.com/aws/aws-sdk-go](https://github.com/aws/aws-sdk-go) | `1.53.5` | `1.53.10` | | [github.com/confluentinc/confluent-kafka-go/v2](https://github.com/confluentinc/confluent-kafka-go) | `2.3.0` | `2.4.0` | | [github.com/databricks/databricks-sql-go](https://github.com/databricks/databricks-sql-go) | `1.5.4` | `1.5.5` | | [github.com/marcboeker/go-duckdb](https://github.com/marcboeker/go-duckdb) | `1.6.4` | `1.6.5` | | [github.com/onsi/ginkgo/v2](https://github.com/onsi/ginkgo) | `2.17.3` | `2.19.0` | | [github.com/trinodb/trino-go-client](https://github.com/trinodb/trino-go-client) | `0.314.0` | `0.315.0` | | [github.com/valyala/fasthttp](https://github.com/valyala/fasthttp) | `1.53.0` | `1.54.0` | | [go.opentelemetry.io/otel](https://github.com/open-telemetry/opentelemetry-go) | `1.26.0` | `1.27.0` | | [google.golang.org/api](https://github.com/googleapis/google-api-go-client) | `0.178.0` | `0.181.0` | Updates `github.com/aws/aws-sdk-go` from 1.53.5 to 1.53.10 - [Release notes](https://github.com/aws/aws-sdk-go/releases) - [Commits](aws/aws-sdk-go@v1.53.5...v1.53.10) Updates `github.com/confluentinc/confluent-kafka-go/v2` from 2.3.0 to 2.4.0 - [Release notes](https://github.com/confluentinc/confluent-kafka-go/releases) - [Changelog](https://github.com/confluentinc/confluent-kafka-go/blob/master/CHANGELOG.md) - [Commits](confluentinc/confluent-kafka-go@v2.3.0...v2.4.0) Updates `github.com/databricks/databricks-sql-go` from 1.5.4 to 1.5.5 - [Release notes](https://github.com/databricks/databricks-sql-go/releases) - [Changelog](https://github.com/databricks/databricks-sql-go/blob/main/CHANGELOG.md) - [Commits](databricks/databricks-sql-go@v1.5.4...v1.5.5) Updates `github.com/marcboeker/go-duckdb` from 1.6.4 to 1.6.5 - [Commits](marcboeker/go-duckdb@v1.6.4...v1.6.5) Updates `github.com/onsi/ginkgo/v2` from 2.17.3 to 2.19.0 - [Release notes](https://github.com/onsi/ginkgo/releases) - [Changelog](https://github.com/onsi/ginkgo/blob/master/CHANGELOG.md) - [Commits](onsi/ginkgo@v2.17.3...v2.19.0) Updates `github.com/trinodb/trino-go-client` from 0.314.0 to 0.315.0 - [Release notes](https://github.com/trinodb/trino-go-client/releases) - [Commits](trinodb/trino-go-client@v0.314.0...v0.315.0) Updates `github.com/valyala/fasthttp` from 1.53.0 to 1.54.0 - [Release notes](https://github.com/valyala/fasthttp/releases) - [Commits](valyala/fasthttp@v1.53.0...1.54.0) Updates `go.opentelemetry.io/otel` from 1.26.0 to 1.27.0 - [Release notes](https://github.com/open-telemetry/opentelemetry-go/releases) - [Changelog](https://github.com/open-telemetry/opentelemetry-go/blob/main/CHANGELOG.md) - [Commits](open-telemetry/opentelemetry-go@v1.26.0...v1.27.0) Updates `golang.org/x/exp` from 0.0.0-20240119083558-1b970713d09a to 0.0.0-20240222234643-814bf88cf225 - [Commits](https://github.com/golang/exp/commits) Updates `google.golang.org/api` from 0.178.0 to 0.181.0 - [Release notes](https://github.com/googleapis/google-api-go-client/releases) - [Changelog](https://github.com/googleapis/google-api-go-client/blob/main/CHANGES.md) - [Commits](googleapis/google-api-go-client@v0.178.0...v0.181.0) --- updated-dependencies: - dependency-name: github.com/aws/aws-sdk-go dependency-type: direct:production update-type: version-update:semver-patch dependency-group: go-deps - dependency-name: github.com/confluentinc/confluent-kafka-go/v2 dependency-type: direct:production update-type: version-update:semver-minor dependency-group: go-deps - dependency-name: github.com/databricks/databricks-sql-go dependency-type: direct:production update-type: version-update:semver-patch dependency-group: go-deps - dependency-name: github.com/marcboeker/go-duckdb dependency-type: direct:production update-type: version-update:semver-patch dependency-group: go-deps - dependency-name: github.com/onsi/ginkgo/v2 dependency-type: direct:production update-type: version-update:semver-minor dependency-group: go-deps - dependency-name: github.com/trinodb/trino-go-client dependency-type: direct:production update-type: version-update:semver-minor dependency-group: go-deps - dependency-name: github.com/valyala/fasthttp dependency-type: direct:production update-type: version-update:semver-minor dependency-group: go-deps - dependency-name: go.opentelemetry.io/otel dependency-type: direct:production update-type: version-update:semver-minor dependency-group: go-deps - dependency-name: golang.org/x/exp dependency-type: direct:production update-type: version-update:semver-patch dependency-group: go-deps - dependency-name: google.golang.org/api dependency-type: direct:production update-type: version-update:semver-minor dependency-group: go-deps ... Signed-off-by: dependabot[bot] <[email protected]> * fix otel * chore: rm docker dep replace * chore: split frequent updates in a new group * chore: add github action linter * chore: update all deps --------- Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the You can disable this status message by setting the Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (invoked as PR comments)
Additionally, you can add CodeRabbit Configration File (
|
* fix: webhook sources name needs to be lower cased * fix: code review suggestion Co-authored-by: Leonidas Vrachnis <[email protected]> * fix: edit in test cases based on code review suggestion --------- Co-authored-by: Leonidas Vrachnis <[email protected]>
…#4748) Bumps the go-deps group with 4 updates in the / directory: [github.com/oschwald/maxminddb-golang](https://github.com/oschwald/maxminddb-golang), [github.com/redis/go-redis/v9](https://github.com/redis/go-redis), [github.com/rudderlabs/sql-tunnels](https://github.com/rudderlabs/sql-tunnels) and [github.com/spf13/viper](https://github.com/spf13/viper). Updates `github.com/oschwald/maxminddb-golang` from 1.12.0 to 1.13.0 - [Release notes](https://github.com/oschwald/maxminddb-golang/releases) - [Commits](oschwald/maxminddb-golang@v1.12.0...v1.13.0) Updates `github.com/redis/go-redis/v9` from 9.5.1 to 9.5.2 - [Release notes](https://github.com/redis/go-redis/releases) - [Changelog](https://github.com/redis/go-redis/blob/master/CHANGELOG.md) - [Commits](redis/go-redis@v9.5.1...v9.5.2) Updates `github.com/rudderlabs/sql-tunnels` from 0.1.6 to 0.1.7 - [Release notes](https://github.com/rudderlabs/sql-tunnels/releases) - [Changelog](https://github.com/rudderlabs/sql-tunnels/blob/main/CHANGELOG.md) - [Commits](rudderlabs/sql-tunnels@v0.1.6...v0.1.7) Updates `github.com/spf13/viper` from 1.18.2 to 1.19.0 - [Release notes](https://github.com/spf13/viper/releases) - [Commits](spf13/viper@v1.18.2...v1.19.0) --- updated-dependencies: - dependency-name: github.com/oschwald/maxminddb-golang dependency-type: direct:production update-type: version-update:semver-minor dependency-group: go-deps - dependency-name: github.com/redis/go-redis/v9 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: go-deps - dependency-name: github.com/rudderlabs/sql-tunnels dependency-type: direct:production update-type: version-update:semver-patch dependency-group: go-deps - dependency-name: github.com/spf13/viper dependency-type: direct:production update-type: version-update:semver-minor dependency-group: go-deps ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
helper/file/file.go
Outdated
func New(parentMod string, opts ...func(*FileHandle)) (*FileHandle, error) { | ||
fileConfig := getFileConfig(parentMod) | ||
fieldsChan := make(chan fields, fileConfig.MaxBatchSize) | ||
|
||
ctx, cancel := context.WithCancel(context.Background()) | ||
g, _ := errgroup.WithContext(ctx) | ||
|
||
handle := &FileHandle{ | ||
dir: "mydebuglogs/", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A few things:
parentMod
is used only for configuration, a bit of an overkill to make required parameterpath
seems very important in our use case, so making it a required parameter. If path is not configure correctly we might end up filling the diskconfig.GetReloadableDurationVar
avoid usingReloadable
variant if it isn't hot reloadable. It can be confusing.- Always prefer DI config, instead of using package-level functions. Thus I suggest passing conf.Conf
please note tabs are broken:
func New(parentMod string, opts ...func(*FileHandle)) (*FileHandle, error) { | |
fileConfig := getFileConfig(parentMod) | |
fieldsChan := make(chan fields, fileConfig.MaxBatchSize) | |
ctx, cancel := context.WithCancel(context.Background()) | |
g, _ := errgroup.WithContext(ctx) | |
handle := &FileHandle{ | |
dir: "mydebuglogs/", | |
func WithOptsFromConfig(prefix string, conf config.Config) { | |
return func(fh *FileHandle) { | |
maxBatchSizeConfPath := fmt.Sprintf("%s.DebugHelper.maxBatchSize", parentMod) | |
maxBatchTimeoutConfPath := fmt.Sprintf("%s.DebugHelper.maxBatchTimeout", parentMod) | |
fh.MaxBatchTimeout = conf.GetDurationVar(20, time.Second, fh.MaxBatchTimeout) | |
fh.MaxBatchSize = conf.GetIntVar(200, 1, fh.MaxBatchSize) | |
} | |
} | |
func New(path string, opts ...func(*FileHandle)) (*FileHandle, error) { | |
fileConfig := getFileConfig(parentMod) | |
fieldsChan := make(chan fields, fileConfig.MaxBatchSize) | |
ctx, cancel := context.WithCancel(context.Background()) | |
g, _ := errgroup.WithContext(ctx) | |
handle := &FileHandle{ | |
dir: path, |
chore: bucket boundaries
- implement better file rotation strategy - make use of locks to carefully rotate & write to buffer - add test file for multiple workers & normal implementation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## chore.rt-delivery-resp-log #4737 +/- ##
==============================================================
- Coverage 74.57% 74.47% -0.10%
==============================================================
Files 414 418 +4
Lines 48649 48867 +218
==============================================================
+ Hits 36280 36396 +116
- Misses 9991 10083 +92
- Partials 2378 2388 +10 ☔ View full report in Codecov by Sentry. |
- inject config as dependency - add benchmarks initial commit - refactor init part of each of the handler implementations
- changed info logs to debug logs - used infof to log about initialisation
This PR is considered to be stale. It has been open 20 days with no further activity thus it is going to be closed in 7 days. To avoid such a case please consider removing the stale label manually or add a comment to the PR. |
Description
Request - Response debug logs for router delivery would be present in files. Whenever we want to look at request-response logs we can download these files
Linear Ticket
Resolves INT-2217
Security