Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,6 @@
import org.apache.ozone.test.GenericTestUtils;

import static org.apache.hadoop.ozone.OzoneConfigKeys.DFS_RATIS_LEADER_ELECTION_MINIMUM_TIMEOUT_DURATION_KEY;
import org.apache.log4j.Level;
import org.apache.log4j.Logger;
import org.apache.ratis.grpc.client.GrpcClientProtocolService;
import org.apache.ratis.protocol.ClientId;
import org.apache.ratis.protocol.GroupInfoReply;
import org.apache.ratis.protocol.GroupInfoRequest;
Expand All @@ -45,7 +42,9 @@
import org.junit.BeforeClass;
import org.junit.Ignore;
import org.junit.Test;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.slf4j.event.Level;

/**
* Test pipeline leader information is correctly used.
Expand All @@ -54,7 +53,7 @@
public class TestRatisPipelineLeader {
private static MiniOzoneCluster cluster;
private static OzoneConfiguration conf;
private static final org.slf4j.Logger LOG =
private static final Logger LOG =
LoggerFactory.getLogger(TestRatisPipelineLeader.class);

@BeforeClass
Expand Down Expand Up @@ -96,9 +95,11 @@ public void testLeaderIdUsedOnFirstCall() throws Exception {
// Verify client connects to Leader without NotLeaderException
XceiverClientRatis xceiverClientRatis =
XceiverClientRatis.newXceiverClientRatis(ratisPipeline, conf);
Logger.getLogger(GrpcClientProtocolService.class).setLevel(Level.DEBUG);
final Logger log = LoggerFactory.getLogger(
"org.apache.ratis.grpc.server.GrpcClientProtocolService");
GenericTestUtils.setLogLevel(log, Level.DEBUG);
GenericTestUtils.LogCapturer logCapturer =
GenericTestUtils.LogCapturer.captureLogs(GrpcClientProtocolService.LOG);
GenericTestUtils.LogCapturer.captureLogs(log);
xceiverClientRatis.connect();
ContainerProtocolCalls.createContainer(xceiverClientRatis, 1L, null);
logCapturer.stopCapturing();
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xs
<declared.ozone.version>${ozone.version}</declared.ozone.version>

<!-- Apache Ratis version -->
<ratis.version>2.3.0-94db58b-SNAPSHOT</ratis.version>
<ratis.version>2.3.0-da5d868-SNAPSHOT</ratis.version>

<!-- Apache Ratis thirdparty version -->
<ratis.thirdparty.version>0.7.0</ratis.thirdparty.version>
Expand Down