Skip to content
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

ir/node: disable log sampling #3011

Merged
merged 1 commit into from
Nov 13, 2024
Merged

ir/node: disable log sampling #3011

merged 1 commit into from
Nov 13, 2024

Conversation

roman-khimov
Copy link
Member

The default Zap config is:

Sampling is enabled at 100:100 by default, meaning that after the first 100 log entries with the same level and message in the same second, it will log every 100th entry with the same level and message in the same second. You may disable this behavior by setting Sampling to nil.

It leads to message loss too easily and we care a lot about each and every object. Notice that it was disabled in NeoGo as well in a52e016c22de2269fcc7362f33317cebfa7e8e4c (nspcc-dev/neo-go#598).

The default Zap config is:

> Sampling is enabled at 100:100 by default, meaning that after the first 100 log entries with the same level and message in the same second, it will log every 100th entry with the same level and message in the same second. You may disable this behavior by setting Sampling to nil.

It leads to message loss too easily and we care a lot about each and every
object. Notice that it was disabled in NeoGo as well
in a52e016c22de2269fcc7362f33317cebfa7e8e4c (nspcc-dev/neo-go#598).

Signed-off-by: Roman Khimov <roman@nspcc.ru>
@roman-khimov roman-khimov added this to the v0.44.0 milestone Nov 13, 2024
Copy link

codecov bot commented Nov 13, 2024

Codecov Report

Attention: Patch coverage is 0% with 2 lines in your changes missing coverage. Please review.

Project coverage is 22.99%. Comparing base (007e992) to head (0ffbfc1).
Report is 19 commits behind head on master.

Files with missing lines Patch % Lines
cmd/neofs-ir/main.go 0.00% 1 Missing ⚠️
cmd/neofs-node/config.go 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #3011      +/-   ##
==========================================
- Coverage   23.06%   22.99%   -0.07%     
==========================================
  Files         790      790              
  Lines       58709    58502     -207     
==========================================
- Hits        13542    13454      -88     
+ Misses      44285    44169     -116     
+ Partials      882      879       -3     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@@ -40,6 +40,7 @@ attribute, which is used for container domain name in NNS contracts (#2954)
- Metabase is refilled if an object exists in write-cache but is missing in metabase (#2977)
- Pprof and metrics services stop at the end of SN's application lifecycle (#2976)
- Reject configuration with unknown fields (#2981)
- Log sampling is disabled by default now (#3011)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

always disabled in fact

@carpawell carpawell merged commit de3938b into master Nov 13, 2024
20 of 22 checks passed
@carpawell carpawell deleted the disable-log-sampling branch November 13, 2024 10:40
roman-khimov added a commit to nspcc-dev/neofs-s3-gw that referenced this pull request Nov 13, 2024
Skipping log lines is not safe to be used by default. Notice that s3-authmate
doesn't have this problem because of the way it constructs its settings.

See also:
 * nspcc-dev/neofs-node#3011
 * nspcc-dev/neo-go#598

Signed-off-by: Roman Khimov <roman@nspcc.ru>
roman-khimov added a commit to nspcc-dev/neo-exporter that referenced this pull request Nov 13, 2024
Skipping log lines is not safe to be used by default. Notice that s3-authmate
doesn't have this problem because of the way it constructs its settings.

See also:
 * nspcc-dev/neofs-node#3011
 * nspcc-dev/neo-go#598

Signed-off-by: Roman Khimov <roman@nspcc.ru>
roman-khimov added a commit to nspcc-dev/neofs-oauthz that referenced this pull request Nov 13, 2024
Skipping log lines is not safe to be used by default. Notice that s3-authmate
doesn't have this problem because of the way it constructs its settings.

See also:
 * nspcc-dev/neofs-node#3011
 * nspcc-dev/neo-go#598

Signed-off-by: Roman Khimov <roman@nspcc.ru>
roman-khimov added a commit to nspcc-dev/neofs-rest-gw that referenced this pull request Nov 13, 2024
Skipping log lines is not safe to be used by default. Notice that s3-authmate
doesn't have this problem because of the way it constructs its settings.

See also:
 * nspcc-dev/neofs-node#3011
 * nspcc-dev/neo-go#598

Signed-off-by: Roman Khimov <roman@nspcc.ru>
carpawell added a commit to nspcc-dev/neofs-oauthz that referenced this pull request Nov 13, 2024
Skipping log lines is not safe to be used by default. Notice that
s3-authmate doesn't have this problem because of the way it constructs
its settings.

See also:
 * nspcc-dev/neofs-node#3011
 * nspcc-dev/neo-go#598
roman-khimov added a commit to nspcc-dev/neofs-rest-gw that referenced this pull request Nov 13, 2024
Skipping log lines is not safe to be used by default.

See also:
 * nspcc-dev/neofs-node#3011
 * nspcc-dev/neo-go#598

Signed-off-by: Roman Khimov <roman@nspcc.ru>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants