diff --git a/src/java/org/apache/cassandra/db/compaction/CompactionManager.java b/src/java/org/apache/cassandra/db/compaction/CompactionManager.java index 5998983a0c..6fe6f01834 100644 --- a/src/java/org/apache/cassandra/db/compaction/CompactionManager.java +++ b/src/java/org/apache/cassandra/db/compaction/CompactionManager.java @@ -121,7 +121,7 @@ public class CompactionManager implements CompactionManagerMBean private final CompactionExecutor executor = new CompactionExecutor(); private final CompactionExecutor validationExecutor = new ValidationExecutor(); - private final static CompactionExecutor cacheCleanupExecutor = new CacheCleanupExecutor(); + private final CompactionExecutor cacheCleanupExecutor = new CacheCleanupExecutor(); private final CompactionExecutor viewBuildExecutor = new ViewBuildExecutor(); private final CompactionMetrics metrics = new CompactionMetrics(executor, validationExecutor, viewBuildExecutor); @@ -1298,7 +1298,7 @@ public class CompactionManager implements CompactionManagerMBean public Bounded(final ColumnFamilyStore cfs, Collection> ranges, Collection> transientRanges, boolean isRepaired, int nowInSec) { super(ranges, nowInSec); - cacheCleanupExecutor.submit(new Runnable() + instance.cacheCleanupExecutor.submit(new Runnable() { @Override public void run() diff --git a/test/conf/logback-dtest.xml b/test/conf/logback-dtest.xml index 7d3a8be751..10efac9b58 100644 --- a/test/conf/logback-dtest.xml +++ b/test/conf/logback-dtest.xml @@ -23,9 +23,6 @@ - - - ./build/test/logs/${cassandra.testtag}/TEST-${suitename}.log @@ -45,7 +42,32 @@ false - + + 0 + 0 + 1024 + + + + + + %-5level %date{HH:mm:ss,SSS} %msg%n + + + WARN + + + + + + %-5level %date{HH:mm:ss,SSS} %msg%n + + + WARN + + + + %-5level [%thread] ${instance_id} %date{ISO8601} %F:%L - %msg%n @@ -54,26 +76,11 @@ - - - - - - - - - - 0 - 0 - 1024 - - true - - - + + + diff --git a/test/distributed/org/apache/cassandra/distributed/LegacyAdapter.java b/test/distributed/org/apache/cassandra/distributed/LegacyAdapter.java new file mode 100644 index 0000000000..1ff88eda75 --- /dev/null +++ b/test/distributed/org/apache/cassandra/distributed/LegacyAdapter.java @@ -0,0 +1,42 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.cassandra.distributed; + +import org.apache.cassandra.config.DatabaseDescriptor; +import org.apache.cassandra.locator.InetAddressAndPort; +import org.apache.cassandra.utils.FBUtilities; + +import java.net.InetAddress; + +public class LegacyAdapter +{ + private static final InetAddressAndPort broadcastAddressAndPort; + static + { + InetAddress address = FBUtilities.getBroadcastAddress(); + int port = DatabaseDescriptor.getStoragePort(); + broadcastAddressAndPort = InetAddressAndPort.getByAddressOverrideDefaults(address, port); + } + + public static InetAddressAndPort getBroadcastAddressAndPort() + { + return broadcastAddressAndPort; + } + +}