Restored log lines to TRACE for notification post alias creation and open/close index

Introduced specific log level for those in OpenCloseIndexTests#testCloseOpenAliasMultipleIndices
This commit is contained in:
Luca Cavanna 2013-09-09 14:10:16 +02:00
parent 9e72683ba4
commit 5fdae8ba10
3 changed files with 6 additions and 5 deletions

View File

@ -257,11 +257,11 @@ public class MetaDataIndexAliasesService extends AbstractComponent {
@Override
public void onAliasesUpdated(NodeAliasesUpdatedAction.NodeAliasesUpdatedResponse response) {
if (version <= response.version()) {
logger.debug("Received NodeAliasesUpdatedResponse with version [{}] from [{}]", response.version(), response.nodeId());
logger.trace("Received NodeAliasesUpdatedResponse with version [{}] from [{}]", response.version(), response.nodeId());
if (countDown.decrementAndGet() == 0) {
aliasOperationPerformedAction.remove(this);
if (notified.compareAndSet(false, true)) {
logger.debug("NodeAliasUpdated was acknowledged by all expected nodes, returning");
logger.trace("NodeAliasUpdated was acknowledged by all expected nodes, returning");
listener.onResponse(new Response(true));
}
}

View File

@ -288,11 +288,11 @@ public class MetaDataIndexStateService extends AbstractComponent {
@Override
public void onIndexStateUpdated(NodeIndicesStateUpdatedAction.NodeIndexStateUpdatedResponse response) {
if (version <= response.version()) {
logger.debug("Received NodeIndexStateUpdatedResponse with version [{}] from [{}]", response.version(), response.nodeId());
logger.trace("Received NodeIndexStateUpdatedResponse with version [{}] from [{}]", response.version(), response.nodeId());
if (countDown.decrementAndGet() == 0) {
indicesStateUpdatedAction.remove(this);
if (notified.compareAndSet(false, true)) {
logger.debug("NodeIndexStateUpdated was acknowledged by all expected nodes, returning");
logger.trace("NodeIndexStateUpdated was acknowledged by all expected nodes, returning");
listener.onResponse(new Response(true));
}
}

View File

@ -29,6 +29,7 @@ import org.elasticsearch.action.support.IgnoreIndices;
import org.elasticsearch.client.Client;
import org.elasticsearch.cluster.metadata.IndexMetaData;
import org.elasticsearch.indices.IndexMissingException;
import org.elasticsearch.junit.annotations.TestLogging;
import org.elasticsearch.test.integration.AbstractSharedClusterTest;
import org.junit.Test;
@ -251,7 +252,7 @@ public class OpenCloseIndexTests extends AbstractSharedClusterTest {
assertIndexIsOpened("test1");
}
@Test
@Test @TestLogging("org.elasticsearch.cluster.metadata:TRACE")
public void testCloseOpenAliasMultipleIndices() {
Client client = client();
createIndex("test1", "test2");