Skip to content

Deprecation messages with the same key but different x-opaque-id are allowed (#44587)#44587

Merged
pgomulka merged 3 commits intoelastic:masterfrom
pgomulka:feature/logging-xopaqueid-duplicates
Jul 22, 2019
Merged

Deprecation messages with the same key but different x-opaque-id are allowed (#44587)#44587
pgomulka merged 3 commits intoelastic:masterfrom
pgomulka:feature/logging-xopaqueid-duplicates

Conversation

@pgomulka
Copy link
Copy Markdown
Contributor

@pgomulka pgomulka commented Jul 18, 2019

Deprecation logger was filtering log entries by key, that means that if two log messages with the same key are logged from different users, then the second log messages will be filtered.
This change allows to log deprecation message with the same key by different users.

relates #41354

We should allow to log the same deprecation type (basing on key) to be
logged if X-Opaque-ID is logged.
@pgomulka pgomulka added :Core/Infra/Logging Log management and logging utilities v8.0.0 labels Jul 18, 2019
@pgomulka pgomulka self-assigned this Jul 18, 2019
@elasticmachine
Copy link
Copy Markdown
Collaborator

Pinging @elastic/es-core-infra

@pgomulka pgomulka requested a review from rjernst July 18, 2019 19:06
@pgomulka pgomulka changed the title Same key deprecation messages from different x-opaque-id not filtered Deprecation messages with the same key but different x-opaque-id should not be filtered Jul 18, 2019
Copy link
Copy Markdown
Member

@rjernst rjernst left a comment

Choose a reason for hiding this comment

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

Looks fine.


public String getXOpaqueId(Set<ThreadContext> threadContexts) {
return threadContexts.stream()
.filter(t -> t.isClosed() == false)
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

nit: spacing seems off here

@pgomulka pgomulka merged commit 4c7764c into elastic:master Jul 22, 2019
@pgomulka pgomulka changed the title Deprecation messages with the same key but different x-opaque-id should not be filtered Deprecation messages with the same key but different x-opaque-id are allowed (#44587) Jul 22, 2019
pgomulka added a commit to pgomulka/elasticsearch that referenced this pull request Jul 22, 2019
…allowed (elastic#44587)

Deprecation logger was filtering log entries by key, that means that if two log messages with the same key are logged from different users, then the second log messages will be filtered.
This change allows to log deprecation message with the same key by different users.

relates elastic#41354
pgomulka added a commit that referenced this pull request Jul 22, 2019
…allowed backport(#44587) #44682

Deprecation logger was filtering log entries by key, that means that if two log messages with the same key are logged from different users, then the second log messages will be filtered.
This change allows to log deprecation message with the same key by different users.

relates #41354
backport #44587
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

:Core/Infra/Logging Log management and logging utilities v7.4.0 v8.0.0-alpha1

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants