-
Notifications
You must be signed in to change notification settings - Fork 281
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
A temporary solution to limit the number of warning messages caused b…
…y class NodeAndClusterIdConverter during tests execution Signed-off-by: Lukasz Soszynski <[email protected]>
- Loading branch information
1 parent
08d6500
commit 67b5446
Showing
2 changed files
with
34 additions
and
2 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
33 changes: 33 additions & 0 deletions
33
src/integrationTest/java/org/opensearch/common/logging/NodeAndClusterIdConverter.java
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,33 @@ | ||
/* | ||
* Copyright OpenSearch Contributors | ||
* SPDX-License-Identifier: Apache-2.0 | ||
* | ||
* The OpenSearch Contributors require contributions made to | ||
* this file be licensed under the Apache-2.0 license or a | ||
* compatible open source license. | ||
* | ||
*/ | ||
package org.opensearch.common.logging; | ||
|
||
/** | ||
* Class uses to override OpenSearch NodeAndClusterIdConverter Log4j2 plugin in order to disable plugin and limit number of | ||
* warn messages like "...ApplierService#updateTask][T#1] WARN ClusterApplierService:628 - failed to notify ClusterStateListener..." | ||
* during tests execution. | ||
* | ||
* The class is rather a temporary solution and the real one should be developed in scope of: | ||
* https://github.com/opensearch-project/OpenSearch/pull/4322 | ||
*/ | ||
import org.apache.logging.log4j.core.LogEvent; | ||
|
||
class NodeAndClusterIdConverter { | ||
|
||
|
||
public NodeAndClusterIdConverter() { | ||
} | ||
|
||
public static void setNodeIdAndClusterId(String nodeId, String clusterUUID) { | ||
} | ||
|
||
public void format(LogEvent event, StringBuilder toAppendTo) { | ||
} | ||
} |