You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@qpid.apache.org by sh...@apache.org on 2011/10/21 03:20:13 UTC
svn commit: r1187150 [41/43] - in /qpid/branches/QPID-2519: ./ bin/ cpp/
cpp/bindings/ cpp/bindings/qmf/python/ cpp/bindings/qmf/ruby/
cpp/bindings/qmf/tests/ cpp/bindings/qmf2/ cpp/bindings/qmf2/examples/cpp/
cpp/bindings/qmf2/python/ cpp/bindings/qmf...
Modified: qpid/branches/QPID-2519/java/systests/src/main/java/org/apache/qpid/test/utils/QpidBrokerTestCase.java
URL: http://svn.apache.org/viewvc/qpid/branches/QPID-2519/java/systests/src/main/java/org/apache/qpid/test/utils/QpidBrokerTestCase.java?rev=1187150&r1=1187149&r2=1187150&view=diff
==============================================================================
--- qpid/branches/QPID-2519/java/systests/src/main/java/org/apache/qpid/test/utils/QpidBrokerTestCase.java (original)
+++ qpid/branches/QPID-2519/java/systests/src/main/java/org/apache/qpid/test/utils/QpidBrokerTestCase.java Fri Oct 21 01:19:00 2011
@@ -25,7 +25,6 @@ import java.io.InputStreamReader;
import java.io.LineNumberReader;
import java.io.PrintStream;
import java.net.MalformedURLException;
-import java.net.URL;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
@@ -52,22 +51,22 @@ import javax.naming.NamingException;
import org.apache.commons.configuration.ConfigurationException;
import org.apache.commons.configuration.XMLConfiguration;
import org.apache.commons.lang.StringUtils;
+import org.apache.log4j.Level;
import org.apache.log4j.Logger;
import org.apache.qpid.AMQException;
+import org.apache.qpid.client.AMQConnection;
import org.apache.qpid.client.AMQConnectionFactory;
import org.apache.qpid.client.AMQQueue;
+import org.apache.qpid.client.transport.TransportConnection;
import org.apache.qpid.exchange.ExchangeDefaults;
import org.apache.qpid.jms.BrokerDetails;
import org.apache.qpid.jms.ConnectionURL;
import org.apache.qpid.management.common.mbeans.ConfigurationManagement;
-import org.apache.qpid.server.Broker;
-import org.apache.qpid.server.BrokerOptions;
-import org.apache.qpid.server.ProtocolExclusion;
import org.apache.qpid.server.configuration.ServerConfiguration;
-import org.apache.qpid.server.protocol.AmqpProtocolVersion;
+import org.apache.qpid.server.registry.ApplicationRegistry;
+import org.apache.qpid.server.registry.ConfigurationFileApplicationRegistry;
import org.apache.qpid.server.store.DerbyMessageStore;
import org.apache.qpid.url.URLSyntaxException;
-import org.apache.qpid.util.FileUtils;
import org.apache.qpid.util.LogMonitor;
/**
@@ -75,14 +74,7 @@ import org.apache.qpid.util.LogMonitor;
*/
public class QpidBrokerTestCase extends QpidTestCase
{
-
- public enum BrokerType
- {
- EXTERNAL /** Test case relies on a Broker started independently of the test-suite */,
- INTERNAL /** Test case starts an embedded broker within this JVM */,
- SPAWNED /** Test case spawns a new broker as a separate process */
- }
- protected final static String QpidHome = System.getProperty("QPID_HOME");
+ protected final String QpidHome = System.getProperty("QPID_HOME");
protected File _configFile = new File(System.getProperty("broker.config"));
protected static final Logger _logger = Logger.getLogger(QpidBrokerTestCase.class);
@@ -90,7 +82,9 @@ public class QpidBrokerTestCase extends
protected long RECEIVE_TIMEOUT = 1000l;
+ private Map<String, String> _propertiesSetForTestOnly = new HashMap<String, String>();
private Map<String, String> _propertiesSetForBroker = new HashMap<String, String>();
+ private Map<Logger, Level> _loggerLevelSetForTest = new HashMap<Logger, Level>();
private XMLConfiguration _testConfiguration = new XMLConfiguration();
private XMLConfiguration _testVirtualhosts = new XMLConfiguration();
@@ -112,10 +106,9 @@ public class QpidBrokerTestCase extends
// system properties
private static final String BROKER_LANGUAGE = "broker.language";
- private static final String BROKER_TYPE = "broker.type";
- private static final String BROKER_COMMAND = "broker.command";
+ private static final String BROKER = "broker";
+ private static final String BROKER_CLEAN = "broker.clean";
private static final String BROKER_CLEAN_BETWEEN_TESTS = "broker.clean.between.tests";
- private static final String BROKER_EXISTING_QPID_WORK = "broker.existing.qpid.work";
private static final String BROKER_VERSION = "broker.version";
protected static final String BROKER_READY = "broker.ready";
private static final String BROKER_STOPPED = "broker.stopped";
@@ -123,29 +116,29 @@ public class QpidBrokerTestCase extends
private static final String BROKER_LOG_INTERLEAVE = "broker.log.interleave";
private static final String BROKER_LOG_PREFIX = "broker.log.prefix";
private static final String BROKER_PERSITENT = "broker.persistent";
- private static final String BROKER_PROTOCOL_EXCLUDES = "broker.protocol.excludes";
-
// values
protected static final String JAVA = "java";
protected static final String CPP = "cpp";
+ protected static final String VM = "vm";
+ protected static final String EXTERNAL = "external";
+ private static final String VERSION_08 = "0-8";
+ private static final String VERSION_010 = "0-10";
protected static final String QPID_HOME = "QPID_HOME";
public static final int DEFAULT_VM_PORT = 1;
public static final int DEFAULT_PORT = Integer.getInteger("test.port", ServerConfiguration.DEFAULT_PORT);
- public static final int FAILING_PORT = Integer.parseInt(System.getProperty("test.port.alt"));
- public static final int DEFAULT_MANAGEMENT_PORT = Integer.getInteger("test.mport", ServerConfiguration.DEFAULT_JMXPORT_REGISTRYSERVER);
- public static final int DEFAULT_SSL_PORT = Integer.getInteger("test.port.ssl", ServerConfiguration.DEFAULT_SSL_PORT);
+ public static final int DEFAULT_MANAGEMENT_PORT = Integer.getInteger("test.mport", ServerConfiguration.DEFAULT_JMXPORT);
+ public static final int DEFAULT_SSL_PORT = Integer.getInteger("test.sslport", ServerConfiguration.DEFAULT_SSL_PORT);
protected String _brokerLanguage = System.getProperty(BROKER_LANGUAGE, JAVA);
- protected BrokerType _brokerType = BrokerType.valueOf(System.getProperty(BROKER_TYPE, "").toUpperCase());
- protected String _brokerCommand = System.getProperty(BROKER_COMMAND);
+ protected String _broker = System.getProperty(BROKER, VM);
+ private String _brokerClean = System.getProperty(BROKER_CLEAN, null);
private Boolean _brokerCleanBetweenTests = Boolean.getBoolean(BROKER_CLEAN_BETWEEN_TESTS);
- private final AmqpProtocolVersion _brokerVersion = AmqpProtocolVersion.valueOf(System.getProperty(BROKER_VERSION, ""));
- protected String _output = System.getProperty(TEST_OUTPUT, System.getProperty("java.io.tmpdir"));
+ private String _brokerVersion = System.getProperty(BROKER_VERSION, VERSION_08);
+ protected String _output = System.getProperty(TEST_OUTPUT);
protected Boolean _brokerPersistent = Boolean.getBoolean(BROKER_PERSITENT);
- private String _brokerProtocolExcludes = System.getProperty(BROKER_PROTOCOL_EXCLUDES);
protected static String _brokerLogPrefix = System.getProperty(BROKER_LOG_PREFIX,"BROKER: ");
protected static boolean _interleaveBrokerLog = Boolean.getBoolean(BROKER_LOG_INTERLEAVE);
@@ -154,11 +147,13 @@ public class QpidBrokerTestCase extends
protected PrintStream _brokerOutputStream;
- protected Map<Integer, BrokerHolder> _brokers = new HashMap<Integer, BrokerHolder>();
+ protected Map<Integer, Process> _brokers = new HashMap<Integer, Process>();
protected InitialContext _initialContext;
protected AMQConnectionFactory _connectionFactory;
+ protected String _testName;
+
// the connections created for a given test
protected List<Connection> _connections = new ArrayList<Connection>();
public static final String QUEUE = "queue";
@@ -200,6 +195,7 @@ public class QpidBrokerTestCase extends
public void runBare() throws Throwable
{
+ _testName = getClass().getSimpleName() + "." + getName();
String qname = getClass().getName() + "." + getName();
// Initialize this for each test run
@@ -214,13 +210,8 @@ public class QpidBrokerTestCase extends
if (redirected)
{
_outputFile = new File(String.format("%s/TEST-%s.out", _output, qname));
- out = new PrintStream(new FileOutputStream(_outputFile), true);
+ out = new PrintStream(_outputFile);
err = new PrintStream(String.format("%s/TEST-%s.err", _output, qname));
-
- // This is relying on behaviour specific to log4j 1.2.12. If we were to upgrade to 1.2.13 or
- // beyond we must change either code (or config) to ensure that ConsoleAppender#setFollow
- // is set to true otherwise log4j logging will not respect the following reassignment.
-
System.setOut(out);
System.setErr(err);
@@ -235,6 +226,7 @@ public class QpidBrokerTestCase extends
}
}
+ _logger.info("========== start " + _testName + " ==========");
try
{
super.runBare();
@@ -255,18 +247,19 @@ public class QpidBrokerTestCase extends
_logger.error("exception stopping broker", e);
}
- // reset properties used in the test
- revertSystemProperties();
- revertLoggingLevels();
-
if(_brokerCleanBetweenTests)
{
- final String qpidWork = System.getProperty("QPID_WORK");
- cleanBrokerWork(qpidWork);
- createBrokerWork(qpidWork);
+ try
+ {
+ cleanBroker();
+ }
+ catch (Exception e)
+ {
+ _logger.error("exception cleaning up broker", e);
+ }
}
- _logger.info("========== stop " + getTestName() + " ==========");
+ _logger.info("========== stop " + _testName + " ==========");
if (redirected)
{
@@ -285,23 +278,11 @@ public class QpidBrokerTestCase extends
@Override
protected void setUp() throws Exception
{
- super.setUp();
-
if (!_configFile.exists())
{
fail("Unable to test without config file:" + _configFile);
}
- String existingQpidWorkPath = System.getProperty(BROKER_EXISTING_QPID_WORK);
- if(existingQpidWorkPath != null && !existingQpidWorkPath.equals(""))
- {
-
- String qpidWork = getQpidWork(_brokerType, getPort());
- File existing = new File(existingQpidWorkPath);
- cleanBrokerWork(qpidWork);
- FileUtils.copyRecursive(existing, new File(qpidWork));
- }
-
startBroker();
}
@@ -402,8 +383,13 @@ public class QpidBrokerTestCase extends
}
}
+ public void startBroker() throws Exception
+ {
+ startBroker(0);
+ }
+
/**
- * Return the management port in use by the broker on this main port
+ * Return the management portin use by the broker on this main port
*
* @param mainPort the broker's main port.
*
@@ -411,7 +397,7 @@ public class QpidBrokerTestCase extends
*/
protected int getManagementPort(int mainPort)
{
- return mainPort + (DEFAULT_MANAGEMENT_PORT - DEFAULT_PORT);
+ return mainPort + (DEFAULT_MANAGEMENT_PORT - (_broker.equals(VM) ? DEFAULT_VM_PORT : DEFAULT_PORT));
}
/**
@@ -426,7 +412,11 @@ public class QpidBrokerTestCase extends
protected int getPort(int port)
{
- if (!_brokerType.equals(BrokerType.EXTERNAL))
+ if (_broker.equals(VM))
+ {
+ return port == 0 ? DEFAULT_VM_PORT : port;
+ }
+ else if (!_broker.equals(EXTERNAL))
{
return port == 0 ? DEFAULT_PORT : port;
}
@@ -438,19 +428,11 @@ public class QpidBrokerTestCase extends
protected String getBrokerCommand(int port) throws MalformedURLException
{
- final int sslPort = port-1;
- final String protocolExcludesList = getProtocolExcludesList(port, sslPort);
- return _brokerCommand
+ return _broker
.replace("@PORT", "" + port)
- .replace("@SSL_PORT", "" + sslPort)
+ .replace("@SSL_PORT", "" + (port - 1))
.replace("@MPORT", "" + getManagementPort(port))
- .replace("@CONFIG_FILE", _configFile.toString())
- .replace("@EXCLUDES", protocolExcludesList);
- }
-
- public void startBroker() throws Exception
- {
- startBroker(0);
+ .replace("@CONFIG_FILE", _configFile.toString());
}
public void startBroker(int port) throws Exception
@@ -461,52 +443,55 @@ public class QpidBrokerTestCase extends
saveTestConfiguration();
saveTestVirtualhosts();
- if(_brokers.get(port) != null)
- {
- throw new IllegalStateException("There is already an existing broker running on port " + port);
- }
-
- if (_brokerType.equals(BrokerType.INTERNAL) && !existingInternalBroker())
+ Process process = null;
+ if (_broker.equals(VM))
{
+ setConfigurationProperty("management.jmxport", String.valueOf(getManagementPort(port)));
setConfigurationProperty(ServerConfiguration.MGMT_CUSTOM_REGISTRY_SOCKET, String.valueOf(false));
saveTestConfiguration();
-
- BrokerOptions options = new BrokerOptions();
- options.setConfigFile(_configFile.getAbsolutePath());
- options.addPort(port);
-
- addExcludedPorts(port, DEFAULT_SSL_PORT, options);
-
- options.setJmxPortRegistryServer(getManagementPort(port));
-
- //Set the log config file, relying on the log4j.configuration system property
- //set on the JVM by the JUnit runner task in module.xml.
- options.setLogConfigFile(new URL(System.getProperty("log4j.configuration")).getFile());
-
- Broker broker = new Broker();
- _logger.info("starting internal broker (same JVM)");
- broker.startup(options);
-
- _brokers.put(port, new InternalBrokerHolder(broker));
+
+ // create an in_VM broker
+ final ConfigurationFileApplicationRegistry registry = new ConfigurationFileApplicationRegistry(_configFile);
+ try
+ {
+ ApplicationRegistry.initialise(registry, port);
+ }
+ catch (Exception e)
+ {
+ _logger.error("Broker initialise failed due to:",e);
+ try
+ {
+ registry.close();
+ }
+ catch (Throwable closeE)
+ {
+ closeE.printStackTrace();
+ }
+ throw e;
+ }
+ TransportConnection.createVMBroker(port);
}
- else if (!_brokerType.equals(BrokerType.EXTERNAL))
+ else if (!_broker.equals(EXTERNAL))
{
- // Add the port to QPID_WORK to ensure unique working dirs for multi broker tests
- final String qpidWork = getQpidWork(_brokerType, port);
String cmd = getBrokerCommand(port);
- _logger.info("starting external broker: " + cmd);
+ _logger.info("starting broker: " + cmd);
ProcessBuilder pb = new ProcessBuilder(cmd.split("\\s+"));
pb.redirectErrorStream(true);
+
Map<String, String> env = pb.environment();
+
String qpidHome = System.getProperty(QPID_HOME);
env.put(QPID_HOME, qpidHome);
+
//Augment Path with bin directory in QPID_HOME.
env.put("PATH", env.get("PATH").concat(File.pathSeparator + qpidHome + "/bin"));
//Add the test name to the broker run.
// DON'T change PNAME, qpid.stop needs this value.
- env.put("QPID_PNAME", "-DPNAME=QPBRKR -DTNAME=\"" + getTestName() + "\"");
- env.put("QPID_WORK", qpidWork);
+ env.put("QPID_PNAME", "-DPNAME=QPBRKR -DTNAME=\"" + _testName + "\"");
+ // Add the port to QPID_WORK to ensure unique working dirs for multi broker tests
+ env.put("QPID_WORK", System.getProperty("QPID_WORK")+ "/" + port);
+
// Use the environment variable to set amqj.logging.level for the broker
// The value used is a 'server' value in the test configuration to
@@ -558,10 +543,7 @@ public class QpidBrokerTestCase extends
}
}
- // cpp broker requires that the work directory is created
- createBrokerWork(qpidWork);
-
- Process process = pb.start();;
+ process = pb.start();
Piper p = new Piper(process.getInputStream(),
_brokerOutputStream,
@@ -575,106 +557,44 @@ public class QpidBrokerTestCase extends
_logger.info("broker failed to become ready (" + p.ready + "):" + p.getStopLine());
//Ensure broker has stopped
process.destroy();
- cleanBrokerWork(qpidWork);
+ cleanBroker();
throw new RuntimeException("broker failed to become ready:"
+ p.getStopLine());
}
try
{
- //test that the broker is still running and hasn't exited unexpectedly
int exit = process.exitValue();
_logger.info("broker aborted: " + exit);
- cleanBrokerWork(qpidWork);
+ cleanBroker();
throw new RuntimeException("broker aborted: " + exit);
}
catch (IllegalThreadStateException e)
{
- // this is expect if the broker started successfully
- }
-
- _brokers.put(port, new SpawnedBrokerHolder(process));
- }
- }
-
- private void addExcludedPorts(int port, int sslPort, BrokerOptions options)
- {
- final String protocolExcludesList = getProtocolExcludesList(port, sslPort);
-
- if (protocolExcludesList.equals(""))
- {
- return;
- }
- final String[] toks = protocolExcludesList.split("\\s");
-
- if(toks.length % 2 != 0)
- {
- throw new IllegalArgumentException("Must be an even number of tokens in '" + protocolExcludesList + "'");
- }
- for (int i = 0; i < toks.length; i=i+2)
- {
- String excludeArg = toks[i];
- final int excludedPort = Integer.parseInt(toks[i+1]);
- options.addExcludedPort(ProtocolExclusion.lookup(excludeArg), excludedPort);
-
- _logger.info("Adding protocol exclusion " + excludeArg + " " + excludedPort);
- }
- }
-
- protected String getProtocolExcludesList(int port, int sslPort)
- {
- final String protocolExcludesList =
- _brokerProtocolExcludes.replace("@PORT", "" + port).replace("@SSL_PORT", "" + sslPort);
- return protocolExcludesList;
- }
-
- private boolean existingInternalBroker()
- {
- for(BrokerHolder holder : _brokers.values())
- {
- if(holder instanceof InternalBrokerHolder)
- {
- return true;
+ // this is expect if the broker started succesfully
}
}
- return false;
- }
-
- private String getQpidWork(BrokerType broker, int port)
- {
- if (!broker.equals(BrokerType.EXTERNAL))
- {
- return System.getProperty("QPID_WORK")+ "/" + port;
- }
-
- return System.getProperty("QPID_WORK");
+ _brokers.put(port, process);
}
public String getTestConfigFile()
{
- return _output + "/" + getTestQueueName() + "-config.xml";
+ String path = _output == null ? System.getProperty("java.io.tmpdir") : _output;
+ return path + "/" + getTestQueueName() + "-config.xml";
}
public String getTestVirtualhostsFile()
{
- return _output + "/" + getTestQueueName() + "-virtualhosts.xml";
- }
-
- private String relativeToQpidHome(String file)
- {
- return file.replace(System.getProperty(QPID_HOME,"QPID_HOME") + "/","");
+ String path = _output == null ? System.getProperty("java.io.tmpdir") : _output;
+ return path + "/" + getTestQueueName() + "-virtualhosts.xml";
}
protected void saveTestConfiguration() throws ConfigurationException
{
- // Specify the test config file
+ // Specifiy the test config file
String testConfig = getTestConfigFile();
- String relative = relativeToQpidHome(testConfig);
-
- setSystemProperty("test.config", relative);
- _logger.info("Set test.config property to: " + relative);
- _logger.info("Saving test virtualhosts file at: " + testConfig);
+ setSystemProperty("test.config", testConfig);
// Create the file if configuration does not exist
if (_testConfiguration.isEmpty())
@@ -686,13 +606,9 @@ public class QpidBrokerTestCase extends
protected void saveTestVirtualhosts() throws ConfigurationException
{
- // Specify the test virtualhosts file
+ // Specifiy the test virtualhosts file
String testVirtualhosts = getTestVirtualhostsFile();
- String relative = relativeToQpidHome(testVirtualhosts);
-
- setSystemProperty("test.virtualhosts", relative);
- _logger.info("Set test.virtualhosts property to: " + relative);
- _logger.info("Saving test virtualhosts file at: " + testVirtualhosts);
+ setSystemProperty("test.virtualhosts", testVirtualhosts);
// Create the file if configuration does not exist
if (_testVirtualhosts.isEmpty())
@@ -702,33 +618,30 @@ public class QpidBrokerTestCase extends
_testVirtualhosts.save(testVirtualhosts);
}
- protected void cleanBrokerWork(final String qpidWork)
+ public void cleanBroker()
{
- if (qpidWork != null)
+ if (_brokerClean != null)
{
- _logger.info("Cleaning broker work dir: " + qpidWork);
+ _logger.info("clean: " + _brokerClean);
+
+ try
+ {
+ ProcessBuilder pb = new ProcessBuilder(_brokerClean.split("\\s+"));
+ pb.redirectErrorStream(true);
+ Process clean = pb.start();
+ new Piper(clean.getInputStream(),_brokerOutputStream).start();
+
+ clean.waitFor();
- File file = new File(qpidWork);
- if (file.exists())
+ _logger.info("clean exited: " + clean.exitValue());
+ }
+ catch (IOException e)
{
- final boolean success = FileUtils.delete(file, true);
- if(!success)
- {
- throw new RuntimeException("Failed to recursively delete beneath : " + file);
- }
+ throw new RuntimeException(e);
}
- }
- }
-
- protected void createBrokerWork(final String qpidWork)
- {
- if (qpidWork != null)
- {
- final File dir = new File(qpidWork);
- dir.mkdirs();
- if (!dir.isDirectory())
+ catch (InterruptedException e)
{
- throw new RuntimeException("Failed to created Qpid work directory : " + qpidWork);
+ throw new RuntimeException(e);
}
}
}
@@ -742,18 +655,21 @@ public class QpidBrokerTestCase extends
{
port = getPort(port);
- _logger.info("stopping broker on port : " + port);
- BrokerHolder broker = _brokers.remove(port);
- broker.shutdown();
+ _logger.info("stopping broker: " + getBrokerCommand(port));
+ Process process = _brokers.remove(port);
+ if (process != null)
+ {
+ process.destroy();
+ process.waitFor();
+ _logger.info("broker exited: " + process.exitValue());
+ }
+ else if (_broker.equals(VM))
+ {
+ TransportConnection.killVMBroker(port);
+ ApplicationRegistry.remove(port);
+ }
}
- public boolean isBrokerPresent(int port) throws Exception
- {
- port = getPort(port);
-
- return _brokers.containsKey(port);
- }
-
/**
* Attempt to set the Java Broker to use the BDBMessageStore for persistence
* Falling back to the DerbyMessageStore if
@@ -895,14 +811,20 @@ public class QpidBrokerTestCase extends
}
/**
- * Set a System property for the client (and broker if using the same vm) of this test.
+ * Set a System (-D) property for the external Broker of this test.
*
* @param property The property to set
* @param value the value to set it to.
*/
protected void setTestClientSystemProperty(String property, String value)
{
- setTestSystemProperty(property, value);
+ if (!_propertiesSetForTestOnly.containsKey(property))
+ {
+ // Record the current value so we can revert it later.
+ _propertiesSetForTestOnly.put(property, System.getProperty(property));
+ }
+
+ System.setProperty(property, value);
}
/**
@@ -910,7 +832,20 @@ public class QpidBrokerTestCase extends
*/
protected void revertSystemProperties()
{
- revertTestSystemProperties();
+ for (String key : _propertiesSetForTestOnly.keySet())
+ {
+ String value = _propertiesSetForTestOnly.get(key);
+ if (value != null)
+ {
+ System.setProperty(key, value);
+ }
+ else
+ {
+ System.clearProperty(key);
+ }
+ }
+
+ _propertiesSetForTestOnly.clear();
// We don't change the current VMs settings for Broker only properties
// so we can just clear this map
@@ -918,7 +853,7 @@ public class QpidBrokerTestCase extends
}
/**
- * Add an environment variable for the external broker environment
+ * Add an environtmen variable for the external broker environment
*
* @param property the property to set
* @param value the value to set it to
@@ -929,23 +864,57 @@ public class QpidBrokerTestCase extends
}
/**
+ * Adjust the VMs Log4j Settings just for this test run
+ *
+ * @param logger the logger to change
+ * @param level the level to set
+ */
+ protected void setLoggerLevel(Logger logger, Level level)
+ {
+ assertNotNull("Cannot set level of null logger", logger);
+ assertNotNull("Cannot set Logger("+logger.getName()+") to null level.",level);
+
+ if (!_loggerLevelSetForTest.containsKey(logger))
+ {
+ // Record the current value so we can revert it later.
+ _loggerLevelSetForTest.put(logger, logger.getLevel());
+ }
+
+ logger.setLevel(level);
+ }
+
+ /**
+ * Restore the logging levels defined by this test.
+ */
+ protected void revertLoggingLevels()
+ {
+ for (Logger logger : _loggerLevelSetForTest.keySet())
+ {
+ logger.setLevel(_loggerLevelSetForTest.get(logger));
+ }
+
+ _loggerLevelSetForTest.clear();
+
+ }
+
+ /**
* Check whether the broker is an 0.8
*
* @return true if the broker is an 0_8 version, false otherwise.
*/
public boolean isBroker08()
{
- return _brokerVersion.equals(AmqpProtocolVersion.v0_8);
+ return _brokerVersion.equals(VERSION_08);
}
public boolean isBroker010()
{
- return _brokerVersion.equals(AmqpProtocolVersion.v0_10);
+ return _brokerVersion.equals(VERSION_010);
}
protected boolean isJavaBroker()
{
- return _brokerLanguage.equals("java") || _brokerType.equals("vm");
+ return _brokerLanguage.equals("java") || _broker.equals("vm");
}
protected boolean isCppBroker()
@@ -955,14 +924,9 @@ public class QpidBrokerTestCase extends
protected boolean isExternalBroker()
{
- return !_brokerType.equals("vm"); //TODO
+ return !_broker.equals("vm");
}
-
- protected boolean isInternalBroker()
- {
- return _brokerType.equals(BrokerType.INTERNAL);
- }
-
+
protected boolean isBrokerStorePersistent()
{
return _brokerPersistent;
@@ -1002,9 +966,9 @@ public class QpidBrokerTestCase extends
* Get the default connection factory for the currently used broker
* Default factory is "local"
*
- * @return A connection factory
+ * @return A conection factory
*
- * @throws Exception if there is an error getting the factory
+ * @throws Exception if there is an error getting the tactory
*/
public AMQConnectionFactory getConnectionFactory() throws NamingException
{
@@ -1028,15 +992,20 @@ public class QpidBrokerTestCase extends
*
* @param factoryName The factory name
*
- * @return A connection factory
+ * @return A conection factory
*
* @throws Exception if there is an error getting the tactory
*/
public AMQConnectionFactory getConnectionFactory(String factoryName) throws NamingException
{
+ if (_broker.equals(VM))
+ {
+ factoryName += ".vm";
+ }
+
return (AMQConnectionFactory) getInitialContext().lookup(factoryName);
}
-
+
public Connection getConnection() throws JMSException, NamingException
{
return getConnection("guest", "guest");
@@ -1066,7 +1035,7 @@ public class QpidBrokerTestCase extends
{
_logger.info("get connection");
Connection con = getConnectionFactory().createConnection(username, password);
- //add the connection in the list of connections
+ //add the connection in the lis of connections
_connections.add(con);
return con;
}
@@ -1074,8 +1043,16 @@ public class QpidBrokerTestCase extends
public Connection getClientConnection(String username, String password, String id) throws JMSException, URLSyntaxException, AMQException, NamingException
{
_logger.info("get Connection");
- Connection con = getConnectionFactory().createConnection(username, password, id);
- //add the connection in the list of connections
+ Connection con;
+ if (_broker.equals(VM))
+ {
+ con = new AMQConnection("vm://:1", username, password, id, "test");
+ }
+ else
+ {
+ con = getConnectionFactory().createConnection(username, password, id);
+ }
+ //add the connection in the lis of connections
_connections.add(con);
return con;
}
@@ -1104,12 +1081,18 @@ public class QpidBrokerTestCase extends
protected void tearDown() throws java.lang.Exception
{
- super.tearDown();
-
- // close all the connections used by this test.
- for (Connection c : _connections)
+ try
{
- c.close();
+ // close all the connections used by this test.
+ for (Connection c : _connections)
+ {
+ c.close();
+ }
+ }
+ finally{
+ // Ensure any problems with close does not interfer with property resets
+ revertSystemProperties();
+ revertLoggingLevels();
}
}
@@ -1166,7 +1149,7 @@ public class QpidBrokerTestCase extends
/**
* Send messages to the given destination.
*
- * If session is transacted then messages will be committed before returning
+ * If session is transacted then messages will be commited before returning
*
* @param session the session to use for sending
* @param destination where to send them to
@@ -1174,7 +1157,7 @@ public class QpidBrokerTestCase extends
*
* @param batchSize the batchSize in which to commit, 0 means no batching,
* but a single commit at the end
- * @return the sent message
+ * @return the sent messgse
*
* @throws Exception
*/
@@ -1187,7 +1170,7 @@ public class QpidBrokerTestCase extends
/**
* Send messages to the given destination.
*
- * If session is transacted then messages will be committed before returning
+ * If session is transacted then messages will be commited before returning
*
* @param session the session to use for sending
* @param destination where to send them to
@@ -1196,7 +1179,7 @@ public class QpidBrokerTestCase extends
* @param offset offset allows the INDEX value of the message to be adjusted.
* @param batchSize the batchSize in which to commit, 0 means no batching,
* but a single commit at the end
- * @return the sent message
+ * @return the sent messgse
*
* @throws Exception
*/
@@ -1207,8 +1190,7 @@ public class QpidBrokerTestCase extends
MessageProducer producer = session.createProducer(destination);
- int i = offset;
- for (; i < (count + offset); i++)
+ for (int i = offset; i < (count + offset); i++)
{
Message next = createNextMessage(session, i);
@@ -1231,7 +1213,7 @@ public class QpidBrokerTestCase extends
// we have no batchSize or
// our count is not divible by batchSize.
if (session.getTransacted() &&
- ( batchSize == 0 || (i-1) % batchSize != 0))
+ ( batchSize == 0 || count % batchSize != 0))
{
session.commit();
}
@@ -1326,26 +1308,29 @@ public class QpidBrokerTestCase extends
*/
public void reloadBrokerSecurityConfig() throws Exception
{
- JMXTestUtils jmxu = new JMXTestUtils(this, "admin" , "admin");
- jmxu.open();
-
- try
+ if (_broker.equals(VM))
{
- ConfigurationManagement configMBean = jmxu.getConfigurationManagement();
- configMBean.reloadSecurityConfiguration();
+ ApplicationRegistry.getInstance().getConfiguration().reparseConfigFileSecuritySections();
}
- finally
+ else
{
- jmxu.close();
- }
-
- LogMonitor _monitor = new LogMonitor(_outputFile);
- assertTrue("The expected server security configuration reload did not occur",
- _monitor.waitForMessage(ServerConfiguration.SECURITY_CONFIG_RELOADED, LOGMONITOR_TIMEOUT));
- }
+ JMXTestUtils jmxu = new JMXTestUtils(this, "admin" , "admin");
+ jmxu.open();
+
+ try
+ {
+ ConfigurationManagement configMBean = jmxu.getConfigurationManagement();
+ configMBean.reloadSecurityConfiguration();
+ }
+ finally
+ {
+ jmxu.close();
+ }
+
+ LogMonitor _monitor = new LogMonitor(_outputFile);
+ assertTrue("The expected server security configuration reload did not occur",
+ _monitor.waitForMessage(ServerConfiguration.SECURITY_CONFIG_RELOADED, LOGMONITOR_TIMEOUT));
- protected int getFailingPort()
- {
- return FAILING_PORT;
+ }
}
}
Propchange: qpid/branches/QPID-2519/java/systests/src/main/java/org/apache/qpid/test/utils/QpidBrokerTestCase.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 21 01:19:00 2011
@@ -2,6 +2,4 @@
/qpid/branches/0.5.x-dev/systests/src/main/java/org/apache/qpid/test/utils/QpidTestCase.java:886720-886722
/qpid/branches/java-broker-0-10/qpid/java/systests/src/main/java/org/apache/qpid/test/utils/QpidTestCase.java:795950-829653
/qpid/branches/java-network-refactor/qpid/java/systests/src/main/java/org/apache/qpid/test/utils/QpidTestCase.java:805429-821809
-/qpid/branches/qpid-2935/qpid/java/systests/src/main/java/org/apache/qpid/test/utils/QpidBrokerTestCase.java:1061302-1072333
-/qpid/trunk/qpid/java/systests/src/main/java/org/apache/qpid/test/utils/QpidBrokerTestCase.java:1072051-1185907
/qpid/trunk/qpid/systests/src/main/java/org/apache/qpid/test/utils/QpidTestCase.java:796646-796653
Modified: qpid/branches/QPID-2519/java/systests/src/main/java/org/apache/qpid/util/LogMonitor.java
URL: http://svn.apache.org/viewvc/qpid/branches/QPID-2519/java/systests/src/main/java/org/apache/qpid/util/LogMonitor.java?rev=1187150&r1=1187149&r2=1187150&view=diff
==============================================================================
--- qpid/branches/QPID-2519/java/systests/src/main/java/org/apache/qpid/util/LogMonitor.java (original)
+++ qpid/branches/QPID-2519/java/systests/src/main/java/org/apache/qpid/util/LogMonitor.java Fri Oct 21 01:19:00 2011
@@ -27,9 +27,11 @@ import org.apache.log4j.SimpleLayout;
import java.io.BufferedReader;
import java.io.File;
import java.io.FileNotFoundException;
+import java.io.FileOutputStream;
import java.io.FileReader;
import java.io.IOException;
-import java.io.LineNumberReader;
+import java.io.OutputStreamWriter;
+import java.util.ArrayList;
import java.util.List;
import java.util.LinkedList;
@@ -43,12 +45,10 @@ import java.util.LinkedList;
public class LogMonitor
{
// The file that the log statements will be written to.
- private final File _logfile;
+ private File _logfile;
// The appender we added to the get messages
- private final FileAppender _appender;
-
- private int _linesToSkip = 0;
+ private FileAppender _appender;
/**
* Create a new LogMonitor that creates a new Log4j Appender and monitors
@@ -78,7 +78,6 @@ public class LogMonitor
if (file != null && file.exists())
{
_logfile = file;
- _appender = null;
}
else
{
@@ -100,13 +99,13 @@ public class LogMonitor
* @param wait the time in ms to wait for the message to occur
* @return true if the message was found
*
- * @throws java.io.FileNotFoundException if the Log file can no longer be found
+ * @throws java.io.FileNotFoundException if the Log file can nolonger be found
* @throws IOException thrown when reading the log file
*/
public List<String> waitAndFindMatches(String message, long wait)
throws FileNotFoundException, IOException
{
- if (waitForMessage(message, wait))
+ if (waitForMessage(message, wait, true))
{
return findMatches(message);
}
@@ -117,9 +116,7 @@ public class LogMonitor
}
/**
- * Checks the log for instances of the search string. If the caller
- * has previously called {@link #markDiscardPoint()}, lines up until the discard
- * point are not considered.
+ * Checks the log for instances of the search string.
*
* The pattern parameter can take any valid argument used in String.contains()
*
@@ -133,99 +130,66 @@ public class LogMonitor
*/
public List<String> findMatches(String pattern) throws IOException
{
-
- List<String> results = new LinkedList<String>();
-
- LineNumberReader reader = new LineNumberReader(new FileReader(_logfile));
- try
- {
- while (reader.ready())
- {
- String line = reader.readLine();
- if (reader.getLineNumber() > _linesToSkip && line.contains(pattern))
- {
- results.add(line);
- }
- }
- }
- finally
- {
- reader.close();
- }
-
- return results;
+ return FileUtils.searchFile(_logfile, pattern);
}
/**
- * Checks the log file for a given message to appear. If the caller
- * has previously called {@link #markDiscardPoint()}, lines up until the discard
- * point are not considered.
+ * Checks the log file for a given message to appear.
*
* @param message the message to wait for in the log
* @param wait the time in ms to wait for the message to occur
+ *
+ * @param printFileOnFailure should we print the contents that have been
+ * read if we fail ot find the message.
* @return true if the message was found
*
- * @throws java.io.FileNotFoundException if the Log file can no longer be found
+ * @throws java.io.FileNotFoundException if the Log file can nolonger be found
* @throws IOException thrown when reading the log file
*/
- public boolean waitForMessage(String message, long wait)
+ public boolean waitForMessage(String message, long wait, boolean printFileOnFailure)
throws FileNotFoundException, IOException
{
// Loop through alerts until we're done or wait ms seconds have passed,
// just in case the logfile takes a while to flush.
- LineNumberReader reader = null;
- try
+ BufferedReader reader = new BufferedReader(new FileReader(_logfile));
+ boolean found = false;
+ long endtime = System.currentTimeMillis() + wait;
+ ArrayList<String> contents = new ArrayList<String>();
+ while (!found && System.currentTimeMillis() < endtime)
{
- reader = new LineNumberReader(new FileReader(_logfile));
-
- boolean found = false;
- long endtime = System.currentTimeMillis() + wait;
- while (!found && System.currentTimeMillis() < endtime)
+ while (reader.ready())
{
- boolean ready = true;
- while (ready = reader.ready())
- {
- String line = reader.readLine();
-
- if (reader.getLineNumber() > _linesToSkip)
- {
- if (line.contains(message))
- {
- found = true;
- break;
- }
- }
- }
- if (!ready)
+ String line = reader.readLine();
+ contents.add(line);
+ if (line.contains(message))
{
- try
- {
- Thread.sleep(50);
- }
- catch (InterruptedException ie)
- {
- Thread.currentThread().interrupt();
- }
+ found = true;
}
}
- return found;
-
}
- finally
+ if (!found && printFileOnFailure)
{
- if (reader != null)
+ for (String line : contents)
{
- reader.close();
+ System.out.println(line);
}
}
+ return found;
}
+
+ public boolean waitForMessage(String message, long alertLogWaitPeriod) throws FileNotFoundException, IOException
+ {
+ return waitForMessage(message, alertLogWaitPeriod, true);
+ }
+
+
/**
* Read the log file in to memory as a String
*
* @return the current contents of the log file
*
- * @throws java.io.FileNotFoundException if the Log file can no longer be found
+ * @throws java.io.FileNotFoundException if the Log file can nolonger be found
* @throws IOException thrown when reading the log file
*/
public String readFile() throws FileNotFoundException, IOException
@@ -244,37 +208,14 @@ public class LogMonitor
}
/**
- * Marks the discard point in the log file.
+ * Clears the log file and writes: 'Log Monitor Reset' at the start of the file
*
- * @throws java.io.FileNotFoundException if the Log file can no longer be found
+ * @throws java.io.FileNotFoundException if the Log file can nolonger be found
* @throws IOException thrown if there is a problem with the log file
*/
- public void markDiscardPoint() throws FileNotFoundException, IOException
- {
- _linesToSkip = countLinesInFile();
- }
-
- private int countLinesInFile() throws IOException
+ public void reset() throws FileNotFoundException, IOException
{
- int lineCount = 0;
- BufferedReader br = null;
- try
- {
- br = new BufferedReader(new FileReader(_logfile));
- while(br.readLine() != null)
- {
- lineCount++;
- }
-
- return lineCount;
- }
- finally
- {
- if (br != null)
- {
- br.close();
- }
- }
+ new FileOutputStream(_logfile).getChannel().truncate(0);
}
/**
Modified: qpid/branches/QPID-2519/java/systests/src/main/java/org/apache/qpid/util/LogMonitorTest.java
URL: http://svn.apache.org/viewvc/qpid/branches/QPID-2519/java/systests/src/main/java/org/apache/qpid/util/LogMonitorTest.java?rev=1187150&r1=1187149&r2=1187150&view=diff
==============================================================================
--- qpid/branches/QPID-2519/java/systests/src/main/java/org/apache/qpid/util/LogMonitorTest.java (original)
+++ qpid/branches/QPID-2519/java/systests/src/main/java/org/apache/qpid/util/LogMonitorTest.java Fri Oct 21 01:19:00 2011
@@ -155,7 +155,7 @@ public class LogMonitorTest extends Test
String notLogged = "This text was not logged";
- validateLogDoesNotContainMessage(_monitor, notLogged);
+ validateLogDoesNotContainsMessage(_monitor, notLogged);
}
public void testWaitForMessage_Timeout() throws IOException
@@ -168,27 +168,28 @@ public class LogMonitorTest extends Test
// Verify that we can time out waiting for a message
assertFalse("Message was logged ",
- _monitor.waitForMessage(message, TIME_OUT / 2));
+ _monitor.waitForMessage(message, TIME_OUT / 2, false));
// Verify that the message did eventually get logged.
assertTrue("Message was never logged.",
_monitor.waitForMessage(message, TIME_OUT));
}
- public void testDiscardPoint() throws IOException
+ public void testReset() throws IOException
{
- String firstMessage = getName() + ": Test Message1";
- Logger.getRootLogger().warn(firstMessage);
+ String message = getName() + ": Test Message";
+
+ Logger.getRootLogger().warn(message);
+
+ validateLogContainsMessage(_monitor, message);
- validateLogContainsMessage(_monitor, firstMessage);
+ String LOG_RESET_TEXT = "Log Monitor Reset";
- _monitor.markDiscardPoint();
+ validateLogDoesNotContainsMessage(_monitor, LOG_RESET_TEXT);
- validateLogDoesNotContainMessage(_monitor, firstMessage);
+ _monitor.reset();
- String secondMessage = getName() + ": Test Message2";
- Logger.getRootLogger().warn(secondMessage);
- validateLogContainsMessage(_monitor, secondMessage);
+ assertEquals("", _monitor.readFile());
}
public void testRead() throws IOException
@@ -213,7 +214,7 @@ public class LogMonitorTest extends Test
*
* @throws IOException if a problems occurs
*/
- protected void validateLogDoesNotContainMessage(LogMonitor log, String message)
+ protected void validateLogDoesNotContainsMessage(LogMonitor log, String message)
throws IOException
{
List<String> results = log.findMatches(message);
Propchange: qpid/branches/QPID-2519/java/systests/src/main/java/systests.log4j
------------------------------------------------------------------------------
--- svn:mergeinfo (added)
+++ svn:mergeinfo Fri Oct 21 01:19:00 2011
@@ -0,0 +1,7 @@
+/qpid/branches/0.5.x-dev/qpid/java/systests/src/main/java/systests.log4j:886720-886722,887145,892761,894875,916304,916325,930288,931179
+/qpid/branches/0.5.x-dev/systests/src/main/java/systests.log4j:886720-886722
+/qpid/branches/java-broker-0-10/qpid/java/systests/src/main/java/systests.log4j:795950-829653
+/qpid/branches/java-network-refactor/qpid/java/systests/src/main/java/systests.log4j:805429-821809
+/qpid/branches/qpid-2935/qpid/java/systests/src/main/java/systests.log4j:1061302-1072333
+/qpid/trunk/qpid/java/systests/src/main/java/systests.log4j:1072051-1185907
+/qpid/trunk/qpid/systests/src/main/java/systests.log4j:796646-796653
Propchange: qpid/branches/QPID-2519/java/test-profiles/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 21 01:19:00 2011
@@ -1,3 +1 @@
/qpid/branches/0.5.x-dev/qpid/java/test-profiles:931179
-/qpid/branches/qpid-2935/qpid/java/test-profiles:1061302-1072333
-/qpid/trunk/qpid/java/test-profiles:1072051-1185907
Modified: qpid/branches/QPID-2519/java/test-profiles/CPPExcludes
URL: http://svn.apache.org/viewvc/qpid/branches/QPID-2519/java/test-profiles/CPPExcludes?rev=1187150&r1=1187149&r2=1187150&view=diff
==============================================================================
--- qpid/branches/QPID-2519/java/test-profiles/CPPExcludes (original)
+++ qpid/branches/QPID-2519/java/test-profiles/CPPExcludes Fri Oct 21 01:19:00 2011
@@ -17,17 +17,11 @@
// under the License.
//
-// QPID-3391: the C++ broker does not currently validate the exchange creation arguments
-org.apache.qpid.test.client.destination.AddressBasedDestinationTest#testCreateExchangeWithNonsenseArgs
-
-//This test requires SSL, but SSL is only enabled for the C++ broker in the cpp.ssl test profile
-//which runs *all* the tests with SSL, so this one can be excluded safely enough
-org.apache.qpid.test.unit.client.AMQSSLConnectionTest#*
-
org.apache.qpid.test.unit.client.channelclose.ChannelCloseTest#*
org.apache.qpid.client.ResetMessageListenerTest#*
// This test is not finished
+org.apache.qpid.test.testcases.TTLTest#*
org.apache.qpid.test.client.failover.FailoverTest#test4MinuteFailover
// Those tests are testing 0.8 specific semantics
@@ -64,6 +58,9 @@ org.apache.qpid.test.unit.client.connect
// 0-10 c++ broker in cpp.testprofile is started with no auth so won't pass this test
org.apache.qpid.test.unit.client.connection.ConnectionTest#testPasswordFailureConnection
+// c++ broker doesn't do selectors, so this will fail
+org.apache.qpid.test.unit.topic.TopicSessionTest#testNonMatchingMessagesDoNotFillQueue
+
// InVM Broker tests
org.apache.qpid.test.client.timeouts.SyncWaitDelayTest#*
@@ -139,10 +136,14 @@ org.apache.qpid.server.failover.MessageD
// These are recent test additions that are failing with the c++ broker
// Temporarily disabling until properly investigated.
+org.apache.qpid.test.unit.publish.DirtyTransactedPublishTest#*
org.apache.qpid.test.unit.ack.FailoverBeforeConsumingRecoverTest#*
org.apache.qpid.test.client.RollbackOrderTest#testOrderingAfterRollbackOnMessage#*
+// Temporarily adding the following until the issues are sorted out.
+org.apache.qpid.test.unit.client.AMQConnectionTest#testHeartBeat
+
//Excluded due to QPID-1447 : CPP broker does not have SlowConsumer Disconnection
org.apache.qpid.systest.GlobalQueuesTest#*
org.apache.qpid.systest.GlobalTopicsTest#*
@@ -164,26 +165,6 @@ org.apache.qpid.server.security.firewall
org.apache.qpid.server.security.firewall.FirewallConfigurationTest#*
org.apache.qpid.server.plugins.PluginTest#*
-// Transacion timeouts not implemented in CPP broker
-org.apache.qpid.test.unit.transacted.TransactionTimeoutDisabledTest#*
-org.apache.qpid.test.unit.transacted.TransactionTimeoutConfigurationTest#*
-org.apache.qpid.test.unit.transacted.TransactionTimeoutTest#*
-
// Java broker only
org.apache.qpid.server.logging.management.LoggingManagementMBeanTest#*
org.apache.qpid.server.management.AMQUserManagementMBeanTest#*
-
-// QPID-3133: On 0-10, the exception listener is currently not invoked when reconnection fails to occurs.
-org.apache.qpid.server.failover.FailoverMethodTest#*
-
-//QPID-3468: exclude QueueBrowser related failover tests
-org.apache.qpid.test.client.QueueBrowserAutoAckTest#testFailoverWithQueueBrowser
-org.apache.qpid.test.client.QueueBrowserAutoAckTest#testFailoverAsQueueBrowserCreated
-org.apache.qpid.test.client.QueueBrowserClientAckTest#testFailoverWithQueueBrowser
-org.apache.qpid.test.client.QueueBrowserClientAckTest#testFailoverAsQueueBrowserCreated
-org.apache.qpid.test.client.QueueBrowserNoAckTest#testFailoverWithQueueBrowser
-org.apache.qpid.test.client.QueueBrowserNoAckTest#testFailoverAsQueueBrowserCreated
-org.apache.qpid.test.client.QueueBrowserPreAckTest#testFailoverWithQueueBrowser
-org.apache.qpid.test.client.QueueBrowserPreAckTest#testFailoverAsQueueBrowserCreated
-org.apache.qpid.test.client.QueueBrowserDupsOkTest#testFailoverWithQueueBrowser
-org.apache.qpid.test.client.QueueBrowserDupsOkTest#testFailoverAsQueueBrowserCreated
Propchange: qpid/branches/QPID-2519/java/test-profiles/CPPExcludes
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 21 01:19:00 2011
@@ -1,5 +1,3 @@
/incubator/qpid/trunk/qpid/java/test-profiles/010Excludes:443187-726139
/qpid/branches/java-broker-0-10/qpid/java/test-profiles/010Excludes:795950-829653
/qpid/branches/java-network-refactor/qpid/java/test-profiles/010Excludes:805429-821809
-/qpid/branches/qpid-2935/qpid/java/test-profiles/CPPExcludes:1061302-1072333
-/qpid/trunk/qpid/java/test-profiles/CPPExcludes:1072051-1185907
Modified: qpid/branches/QPID-2519/java/test-profiles/CPPTransientExcludes
URL: http://svn.apache.org/viewvc/qpid/branches/QPID-2519/java/test-profiles/CPPTransientExcludes?rev=1187150&r1=1187149&r2=1187150&view=diff
==============================================================================
--- qpid/branches/QPID-2519/java/test-profiles/CPPTransientExcludes (original)
+++ qpid/branches/QPID-2519/java/test-profiles/CPPTransientExcludes Fri Oct 21 01:19:00 2011
@@ -27,6 +27,3 @@ org.apache.qpid.test.unit.xa.TopicTest#t
org.apache.qpid.test.unit.xa.TopicTest#testRecover
org.apache.qpid.test.unit.xa.QueueTest#testRecover
org.apache.qpid.test.unit.xa.QueueTest#testSendAndRecover
-
-// test requires a persistent store
-org.apache.qpid.test.unit.ack.ClientAcknowledgeTest#testClientAckWithLargeFlusherPeriod
Modified: qpid/branches/QPID-2519/java/test-profiles/Excludes
URL: http://svn.apache.org/viewvc/qpid/branches/QPID-2519/java/test-profiles/Excludes?rev=1187150&r1=1187149&r2=1187150&view=diff
==============================================================================
--- qpid/branches/QPID-2519/java/test-profiles/Excludes (original)
+++ qpid/branches/QPID-2519/java/test-profiles/Excludes Fri Oct 21 01:19:00 2011
@@ -17,6 +17,13 @@
// under the License.
//
+org.apache.qpid.client.MultipleJCAProviderRegistrationTest#test
+// QPID-1715, QPID-1715 : Client Error Handling on close is still broken
+org.apache.qpid.server.queue.QueueCreateTest#testCreatePriorityString
+org.apache.qpid.server.queue.QueueCreateTest#testCreateFlowToDiskValidNoSize
+org.apache.qpid.server.queue.QueueCreateTest#testCreateFlowToDiskInvalid
+org.apache.qpid.server.queue.QueueCreateTest#testCreateFlowToDiskInvalidSize
+
//
// QPID-2031 : Broker is not cleanly shutdown by QpidTestCase
//
@@ -26,7 +33,7 @@ org.apache.qpid.server.logging.BrokerLog
org.apache.qpid.server.logging.VirtualHostLoggingTest#testVirtualhostClosure
org.apache.qpid.server.logging.MemoryMessageStoreLoggingTest#testMessageStoreClose
-// QPID-3424 : Test fails to start external broker due to Derby Exception.
+// QPID-XXX : Test fails to start external broker due to Derby Exception.
org.apache.qpid.server.logging.DerbyMessageStoreLoggingTest#*
// QPID-1816 : Client Ack has not been addressed
@@ -44,4 +51,3 @@ org.apache.qpid.test.unit.ack.Acknowledg
// QPID-2418 : The queue backing the dur sub is not currently deleted at subscription change, so the test will fail.
org.apache.qpid.test.unit.ct.DurableSubscriberTest#testResubscribeWithChangedSelectorAndRestart
-org.apache.qpid.client.ssl.SSLTest#testVerifyLocalHostLocalDomain
Propchange: qpid/branches/QPID-2519/java/test-profiles/Excludes
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 21 01:19:00 2011
@@ -1,5 +1,3 @@
/incubator/qpid/trunk/qpid/java/test-profiles/Excludes:443187-726139
/qpid/branches/java-broker-0-10/qpid/java/test-profiles/Excludes:795950-829653
/qpid/branches/java-network-refactor/qpid/java/test-profiles/Excludes:805429-821809
-/qpid/branches/qpid-2935/qpid/java/test-profiles/Excludes:1061302-1072333
-/qpid/trunk/qpid/java/test-profiles/Excludes:1072051-1185907
Modified: qpid/branches/QPID-2519/java/test-profiles/Java010Excludes
URL: http://svn.apache.org/viewvc/qpid/branches/QPID-2519/java/test-profiles/Java010Excludes?rev=1187150&r1=1187149&r2=1187150&view=diff
==============================================================================
--- qpid/branches/QPID-2519/java/test-profiles/Java010Excludes (original)
+++ qpid/branches/QPID-2519/java/test-profiles/Java010Excludes Fri Oct 21 01:19:00 2011
@@ -37,6 +37,9 @@ org.apache.qpid.test.client.FlowControlT
// 0-10 protocol doesn't support message bouncing
org.apache.qpid.server.exchange.ReturnUnroutableMandatoryMessageTest#*
+// QPID-1727 , QPID-1726 :c++ broker does not support flow to disk on transient queues. Also it requries a persistent store impl. for Apache
+org.apache.qpid.test.client.QueueBrowsingFlowToDiskTest#*
+
// 0-10 and 0-9 connections dont generate the exact same logging due to protocol differences
org.apache.qpid.server.logging.ChannelLoggingTest#testChannelStartsFlowStopped
org.apache.qpid.server.logging.ChannelLoggingTest#testChannelStartConsumerFlowStarted
@@ -44,49 +47,35 @@ org.apache.qpid.server.logging.Subscript
// 0-10 Broker does not have a JMX connection MBean
org.apache.qpid.management.jmx.ManagementActorLoggingTest#testConnectionCloseViaManagement
-org.apache.qpid.management.jmx.MessageConnectionStatisticsTest#*
+
+// 0-10 has different ideas about clientid and ownership of queues
+org.apache.qpid.server.queue.ModelTest#*
// 0-10 is not supported by the MethodRegistry
org.apache.qpid.test.unit.close.JavaServerCloseRaceConditionTest#*
+// QPID-2084 : this test needs more work for 0-10
+org.apache.qpid.test.unit.client.DynamicQueueExchangeCreateTest#*
+
//QPID-942 : Implemented Channel.Flow based Producer Side flow control to the Java Broker (not in CPP Broker)
org.apache.qpid.server.queue.ProducerFlowControlTest#*
//QPID-1950 : Commit to test this failure. This is a MINA only failure so it cannot be tested when using 010.
org.apache.qpid.server.failover.MessageDisappearWithIOExceptionTest#*
-//QPID-1864: rollback with subscriptions does not work in 0-10 yet
-org.apache.qpid.test.client.RollbackOrderTest#testOrderingAfterRollbackOnMessage
-
-// This test uses 0-8 channel frames
-org.apache.qpid.test.unit.client.channelclose.ChannelCloseTest#*
+//QPID-2471 : Issues with 0-10 recovery
+org.apache.qpid.test.unit.ack.RecoverTest#testRecoverInAutoAckListener
+org.apache.qpid.test.unit.ack.FailoverBeforeConsumingRecoverTest#testRecoverInAutoAckListener
-//QPID-3422: test fails because ring queue is not implemented on java broker
-org.apache.qpid.test.client.destination.AddressBasedDestinationTest#testBrowseMode
+// Temporarily disabling until properly investigated.
+org.apache.qpid.test.unit.publish.DirtyTransactedPublishTest#*
-// QPID-3133: On 0-10, the exception listener is currently not invoked when reconnection fails to occurs.
-org.apache.qpid.server.failover.FailoverMethodTest#*
+//rollback with subscriptions does not work in 0-10 yet
+org.apache.qpid.test.client.RollbackOrderTest#testOrderingAfterRollbackOnMessage
+org.apache.qpid.test.unit.ack.RecoverTest#testRecoverInAutoAckListener
-// QPID-3392: the Java broker does not yet implement exchange creation arguments
-org.apache.qpid.test.client.destination.AddressBasedDestinationTest#testCreateExchangeWithArgs
-org.apache.qpid.test.client.destination.AddressBasedDestinationTest#testSessionCreateTopicWithExchangeArgs
-
-// QPID-1935: the following tests are failing on 0.10 profiles
-org.apache.qpid.test.client.QueueBrowserTransactedTest#testFailoverAsQueueBrowserCreated
-org.apache.qpid.test.client.QueueBrowserTransactedTest#testFailoverWithQueueBrowser
-
-// QPID-3432: These tests test the behaviour of 0-8..-0-9-1 specific system property (amqj.default_syncwrite_timeout)
-org.apache.qpid.test.client.timeouts.SyncWaitTimeoutDelayTest#*
-org.apache.qpid.test.client.timeouts.SyncWaitDelayTest#*
-
-//QPID-3468: exclude QueueBrowser related failover tests
-org.apache.qpid.test.client.QueueBrowserAutoAckTest#testFailoverWithQueueBrowser
-org.apache.qpid.test.client.QueueBrowserAutoAckTest#testFailoverAsQueueBrowserCreated
-org.apache.qpid.test.client.QueueBrowserClientAckTest#testFailoverWithQueueBrowser
-org.apache.qpid.test.client.QueueBrowserClientAckTest#testFailoverAsQueueBrowserCreated
-org.apache.qpid.test.client.QueueBrowserNoAckTest#testFailoverWithQueueBrowser
-org.apache.qpid.test.client.QueueBrowserNoAckTest#testFailoverAsQueueBrowserCreated
-org.apache.qpid.test.client.QueueBrowserPreAckTest#testFailoverWithQueueBrowser
-org.apache.qpid.test.client.QueueBrowserPreAckTest#testFailoverAsQueueBrowserCreated
-org.apache.qpid.test.client.QueueBrowserDupsOkTest#testFailoverWithQueueBrowser
-org.apache.qpid.test.client.QueueBrowserDupsOkTest#testFailoverAsQueueBrowserCreated
+//Temporarily adding the following until the issues are sorted out.
+//Should probably raise JIRAs for them.
+org.apache.qpid.transport.network.mina.MINANetworkDriverTest#*
+org.apache.qpid.test.client.destination.AddressBasedDestinationTest#testCreateExchange
+org.apache.qpid.test.client.destination.AddressBasedDestinationTest#testBrowseMode
Modified: qpid/branches/QPID-2519/java/test-profiles/JavaExcludes
URL: http://svn.apache.org/viewvc/qpid/branches/QPID-2519/java/test-profiles/JavaExcludes?rev=1187150&r1=1187149&r2=1187150&view=diff
==============================================================================
--- qpid/branches/QPID-2519/java/test-profiles/JavaExcludes (original)
+++ qpid/branches/QPID-2519/java/test-profiles/JavaExcludes Fri Oct 21 01:19:00 2011
@@ -17,29 +17,38 @@
// under the License.
//
-// QPID-1823: this takes ages to run
-org.apache.qpid.client.SessionCreateTest#*
-
-//QPID-2845: The queue policy types used by the C++ broker are not currently supported by the Java broker
-org.apache.qpid.test.client.queue.QueuePolicyTest#testRingPolicy
-org.apache.qpid.test.client.queue.QueuePolicyTest#testRejectPolicy
+// Those tests are not finished
+org.apache.qpid.test.testcases.TTLTest#*
+org.apache.qpid.test.testcases.FailoverTest#*
-///////////////////////////////////////////////////////
-//Moved from JavaStandaloneExcludes when it was removed
-///////////////////////////////////////////////////////
-
-// QPID-3426: The following test is broken.
// This is a long running test so should exclude from normal runs
org.apache.qpid.test.client.failover.FailoverTest#test4MinuteFailover
-// This test may use QpidTestCase but it is not using the getConnection and is hardwired to InVM
-org.apache.qpid.test.unit.client.connection.CloseAfterConnectionFailureTest#*
-
-//QPID-1818, QPID-1821 : Client code path does not correctly restore a transacted session after failover.
+//QPID-1818 : Client code path does not correctly restore a transacted session after failover.
org.apache.qpid.server.persistent.NoLocalAfterRecoveryTest#*
-//XA functionality is not fully implemented yet
-org.apache.qpid.jms.xa.XAResourceTest#*
+// QPID-1823: this takes ages to run
+org.apache.qpid.client.SessionCreateTest#*
+
+// related to QPID-2471. Temporarily disabling these tests until I figure out why they are failing with the Java broker.
+org.apache.qpid.test.unit.ack.RecoverTest#testRecoverResendsMsgs
+org.apache.qpid.test.unit.ack.RecoverTest#testRecoverResendsMsgsAckOnEarlier
+org.apache.qpid.test.unit.ack.RecoverTest#testAcknowledgePerConsumer
+org.apache.qpid.test.unit.ack.FailoverBeforeConsumingRecoverTest#testRecoverResendsMsgs
+org.apache.qpid.test.unit.ack.FailoverBeforeConsumingRecoverTest#testRecoverResendsMsgsAckOnEarlier
+org.apache.qpid.test.unit.ack.FailoverBeforeConsumingRecoverTest#testAcknowledgePerConsumer
+
+// related to QPID-2471. These are new test cases and fail with the Java broker.
+org.apache.qpid.test.unit.ack.RecoverTest#testOderingWithAsyncConsumer
+org.apache.qpid.test.unit.ack.RecoverTest#testOderingWithSyncConsumer
+org.apache.qpid.test.unit.ack.FailoverBeforeConsumingRecoverTest#testOderingWithAsyncConsumer
+org.apache.qpid.test.unit.ack.FailoverBeforeConsumingRecoverTest#testOderingWithSyncConsumer
+
+org.apache.qpid.test.client.queue.LVQTest#*
-//The Java broker doesnt support client auth
-org.apache.qpid.client.ssl.SSLTest#testMultipleCertsInSingleStore
+// Session resume is not supported in the Java client
+org.apache.qpid.transport.ConnectionTest#testResumeNonemptyReplayBuffer
+
+//QPID-2845: The queue policy types used by the C++ broker are not currently supported by the Java broker
+org.apache.qpid.test.client.queue.QueuePolicyTest#testRingPolicy
+org.apache.qpid.test.client.queue.QueuePolicyTest#testRejectPolicy
Propchange: qpid/branches/QPID-2519/java/test-profiles/JavaExcludes
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 21 01:19:00 2011
@@ -1,5 +1,3 @@
/incubator/qpid/trunk/qpid/java/test-profiles/08Excludes:443187-726139
/qpid/branches/java-broker-0-10/qpid/java/test-profiles/08Excludes:795950-829653
/qpid/branches/java-network-refactor/qpid/java/test-profiles/08Excludes:805429-821809
-/qpid/branches/qpid-2935/qpid/java/test-profiles/JavaExcludes:1061302-1072333
-/qpid/trunk/qpid/java/test-profiles/JavaExcludes:1072051-1185907
Modified: qpid/branches/QPID-2519/java/test-profiles/JavaTransientExcludes
URL: http://svn.apache.org/viewvc/qpid/branches/QPID-2519/java/test-profiles/JavaTransientExcludes?rev=1187150&r1=1187149&r2=1187150&view=diff
==============================================================================
--- qpid/branches/QPID-2519/java/test-profiles/JavaTransientExcludes (original)
+++ qpid/branches/QPID-2519/java/test-profiles/JavaTransientExcludes Fri Oct 21 01:19:00 2011
@@ -19,7 +19,6 @@
//These tests require a persistent store
org.apache.qpid.server.store.PersistentStoreTest#*
-org.apache.qpid.test.unit.ack.ClientAcknowledgeTest#testClientAckWithLargeFlusherPeriod
org.apache.qpid.test.unit.ct.DurableSubscriberTest#*
@@ -31,6 +30,3 @@ org.apache.qpid.server.store.MessageStor
org.apache.qpid.server.store.MessageStoreTest#testDurableQueueRemoval
org.apache.qpid.server.store.MessageStoreTest#testExchangePersistence
org.apache.qpid.server.store.MessageStoreTest#testDurableExchangeRemoval
-
-org.apache.qpid.server.store.berkeleydb.BDBMessageStoreTest#*
-org.apache.qpid.server.store.berkeleydb.BDBUpgradeTest#*
Propchange: qpid/branches/QPID-2519/java/test-profiles/JavaTransientExcludes
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 21 01:19:00 2011
@@ -1,5 +1,3 @@
/incubator/qpid/trunk/qpid/java/test-profiles/08TransientExcludes:443187-726139
/qpid/branches/java-broker-0-10/qpid/java/test-profiles/08TransientExcludes:795950-829653
/qpid/branches/java-network-refactor/qpid/java/test-profiles/08TransientExcludes:805429-821809
-/qpid/branches/qpid-2935/qpid/java/test-profiles/JavaTransientExcludes:1061302-1072333
-/qpid/trunk/qpid/java/test-profiles/JavaTransientExcludes:1072051-1185907
Propchange: qpid/branches/QPID-2519/java/test-profiles/XAExcludes
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 21 01:19:00 2011
@@ -1,5 +1,3 @@
/incubator/qpid/trunk/qpid/java/test-profiles/XAExcludes:443187-726139
/qpid/branches/java-broker-0-10/qpid/java/test-profiles/XAExcludes:795950-829653
/qpid/branches/java-network-refactor/qpid/java/test-profiles/XAExcludes:805429-821809
-/qpid/branches/qpid-2935/qpid/java/test-profiles/XAExcludes:1061302-1072333
-/qpid/trunk/qpid/java/test-profiles/XAExcludes:1072051-1185907
Modified: qpid/branches/QPID-2519/java/test-profiles/cpp.async.testprofile
URL: http://svn.apache.org/viewvc/qpid/branches/QPID-2519/java/test-profiles/cpp.async.testprofile?rev=1187150&r1=1187149&r2=1187150&view=diff
==============================================================================
--- qpid/branches/QPID-2519/java/test-profiles/cpp.async.testprofile (original)
+++ qpid/branches/QPID-2519/java/test-profiles/cpp.async.testprofile Fri Oct 21 01:19:00 2011
@@ -19,5 +19,3 @@
include=cpp
profile.excludes=CPPPrefetchExcludes
broker.modules=--load-module ${broker.module.store}
-broker.persistent=true
-
Propchange: qpid/branches/QPID-2519/java/test-profiles/cpp.async.testprofile
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 21 01:19:00 2011
@@ -1,5 +1,3 @@
/incubator/qpid/trunk/qpid/java/test-profiles/cpp.async.testprofile:443187-726139
/qpid/branches/java-broker-0-10/qpid/java/test-profiles/cpp.async.testprofile:795950-829653
/qpid/branches/java-network-refactor/qpid/java/test-profiles/cpp.async.testprofile:805429-821809
-/qpid/branches/qpid-2935/qpid/java/test-profiles/cpp.async.testprofile:1061302-1072333
-/qpid/trunk/qpid/java/test-profiles/cpp.async.testprofile:1072051-1185907
Propchange: qpid/branches/QPID-2519/java/test-profiles/cpp.cluster.testprofile
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 21 01:19:00 2011
@@ -1,5 +1,3 @@
/incubator/qpid/trunk/qpid/java/test-profiles/cpp.cluster.testprofile:443187-726139
/qpid/branches/java-broker-0-10/qpid/java/test-profiles/cpp.cluster.testprofile:795950-829653
/qpid/branches/java-network-refactor/qpid/java/test-profiles/cpp.cluster.testprofile:805429-821809
-/qpid/branches/qpid-2935/qpid/java/test-profiles/cpp.cluster.testprofile:1061302-1072333
-/qpid/trunk/qpid/java/test-profiles/cpp.cluster.testprofile:1072051-1185907
Propchange: qpid/branches/QPID-2519/java/test-profiles/cpp.noprefetch.testprofile
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 21 01:19:00 2011
@@ -1,5 +1,3 @@
/incubator/qpid/trunk/qpid/java/test-profiles/cpp.noprefetch.testprofile:443187-726139
/qpid/branches/java-broker-0-10/qpid/java/test-profiles/cpp.noprefetch.testprofile:795950-829653
/qpid/branches/java-network-refactor/qpid/java/test-profiles/cpp.noprefetch.testprofile:805429-821809
-/qpid/branches/qpid-2935/qpid/java/test-profiles/cpp.noprefetch.testprofile:1061302-1072333
-/qpid/trunk/qpid/java/test-profiles/cpp.noprefetch.testprofile:1072051-1185907
Modified: qpid/branches/QPID-2519/java/test-profiles/cpp.ssl.excludes
URL: http://svn.apache.org/viewvc/qpid/branches/QPID-2519/java/test-profiles/cpp.ssl.excludes?rev=1187150&r1=1187149&r2=1187150&view=diff
==============================================================================
--- qpid/branches/QPID-2519/java/test-profiles/cpp.ssl.excludes (original)
+++ qpid/branches/QPID-2519/java/test-profiles/cpp.ssl.excludes Fri Oct 21 01:19:00 2011
@@ -18,10 +18,3 @@
//
#org.apache.qpid.test.client.failover.FailoverTest#*
-
-//This test does not supply a client keystore, therefore it cant login to the C++ broker
-//in this test profile as it demands client certificate authentication
-org.apache.qpid.client.ssl.SSLTest#testCreateSSLConnectionUsingConnectionURLParamsTrustStoreOnly
-
-//QPID-3431: excluding because this takes 30+ mins to run on the C++ SSL profile for some reason
-org.apache.qpid.client.SessionCreateTest#testSessionCreationLimit
Propchange: qpid/branches/QPID-2519/java/test-profiles/cpp.ssl.excludes
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 21 01:19:00 2011
@@ -1,5 +1,3 @@
/incubator/qpid/trunk/qpid/java/test-profiles/cpp.ssl.excludes:443187-726139
/qpid/branches/java-broker-0-10/qpid/java/test-profiles/cpp.ssl.excludes:795950-829653
/qpid/branches/java-network-refactor/qpid/java/test-profiles/cpp.ssl.excludes:805429-821809
-/qpid/branches/qpid-2935/qpid/java/test-profiles/cpp.ssl.excludes:1061302-1072333
-/qpid/trunk/qpid/java/test-profiles/cpp.ssl.excludes:1072051-1185907
Modified: qpid/branches/QPID-2519/java/test-profiles/cpp.ssl.testprofile
URL: http://svn.apache.org/viewvc/qpid/branches/QPID-2519/java/test-profiles/cpp.ssl.testprofile?rev=1187150&r1=1187149&r2=1187150&view=diff
==============================================================================
--- qpid/branches/QPID-2519/java/test-profiles/cpp.ssl.testprofile (original)
+++ qpid/branches/QPID-2519/java/test-profiles/cpp.ssl.testprofile Fri Oct 21 01:19:00 2011
@@ -23,7 +23,7 @@ broker.modules=--load-module ${broker.mo
profile.use_ssl=true
broker.ready= Listening for SSL connections
-javax.net.ssl.keyStore=${test.profiles}/test_resources/ssl/java_client_keystore.jks
+javax.net.ssl.keyStore=${test.profiles}/test_resources/ssl/keystore.jks
javax.net.ssl.keyStorePassword=password
-javax.net.ssl.trustStore=${test.profiles}/test_resources/ssl/java_client_truststore.jks
+javax.net.ssl.trustStore=${test.profiles}/test_resources/ssl/certstore.jks
javax.net.ssl.trustStorePassword=password
Propchange: qpid/branches/QPID-2519/java/test-profiles/cpp.ssl.testprofile
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 21 01:19:00 2011
@@ -1,5 +1,3 @@
/incubator/qpid/trunk/qpid/java/test-profiles/cpp.ssl.testprofile:443187-726139
/qpid/branches/java-broker-0-10/qpid/java/test-profiles/cpp.ssl.testprofile:795950-829653
/qpid/branches/java-network-refactor/qpid/java/test-profiles/cpp.ssl.testprofile:805429-821809
-/qpid/branches/qpid-2935/qpid/java/test-profiles/cpp.ssl.testprofile:1061302-1072333
-/qpid/trunk/qpid/java/test-profiles/cpp.ssl.testprofile:1072051-1185907
Modified: qpid/branches/QPID-2519/java/test-profiles/cpp.testprofile
URL: http://svn.apache.org/viewvc/qpid/branches/QPID-2519/java/test-profiles/cpp.testprofile?rev=1187150&r1=1187149&r2=1187150&view=diff
==============================================================================
--- qpid/branches/QPID-2519/java/test-profiles/cpp.testprofile (original)
+++ qpid/branches/QPID-2519/java/test-profiles/cpp.testprofile Fri Oct 21 01:19:00 2011
@@ -16,7 +16,7 @@
# specific language governing permissions and limitations
# under the License.
#
-broker.version=v0_10
+broker.version=0-10
broker.language=cpp
broker.dir=${project.root}/../cpp/src
@@ -32,8 +32,7 @@ broker.stopped=Exception constructed
broker.modules=
broker.args=
-broker.type=spawned
-broker.command=${broker.executable} -p @PORT --data-dir ${project.root}/build/work/@PORT -t --auth no --no-module-dir ${broker.modules} ${broker.args}
+broker=${broker.executable} -p @PORT --data-dir ${build.data}/@PORT -t --auth no --no-module-dir ${broker.modules} ${broker.args}
profile.excludes=CPPPrefetchExcludes CPPTransientExcludes
test.excludes=Excludes CPPExcludes ${profile}.excludes ${profile.excludes} cpp.excludes
Propchange: qpid/branches/QPID-2519/java/test-profiles/cpp.testprofile
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 21 01:19:00 2011
@@ -1,5 +1,3 @@
/incubator/qpid/trunk/qpid/java/test-profiles/cpp.testprofile:443187-726139
/qpid/branches/java-broker-0-10/qpid/java/test-profiles/cpp.testprofile:795950-829653
/qpid/branches/java-network-refactor/qpid/java/test-profiles/cpp.testprofile:805429-821809
-/qpid/branches/qpid-2935/qpid/java/test-profiles/cpp.testprofile:1061302-1072333
-/qpid/trunk/qpid/java/test-profiles/cpp.testprofile:1072051-1185907
Modified: qpid/branches/QPID-2519/java/test-profiles/log4j-test.xml
URL: http://svn.apache.org/viewvc/qpid/branches/QPID-2519/java/test-profiles/log4j-test.xml?rev=1187150&r1=1187149&r2=1187150&view=diff
==============================================================================
--- qpid/branches/QPID-2519/java/test-profiles/log4j-test.xml (original)
+++ qpid/branches/QPID-2519/java/test-profiles/log4j-test.xml Fri Oct 21 01:19:00 2011
@@ -59,6 +59,10 @@
<level value="ERROR"/>
</logger>
+ <logger name="org.apache.qpid.server.virtualhost.VirtualHostImpl$1HouseKeepingTask">
+ <level value="WARN"/>
+ </logger>
+
<root>
<level value="${root.logging.level}"/>
<appender-ref ref="console" />
Propchange: qpid/branches/QPID-2519/java/test-profiles/log4j-test.xml
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 21 01:19:00 2011
@@ -2,5 +2,3 @@
/qpid/branches/0.5.x-dev/qpid/java/test-profiles/log4j-test.xml:931179
/qpid/branches/java-broker-0-10/qpid/java/test-profiles/log4j-test.xml:795950-829653
/qpid/branches/java-network-refactor/qpid/java/test-profiles/log4j-test.xml:805429-821809
-/qpid/branches/qpid-2935/qpid/java/test-profiles/log4j-test.xml:1061302-1072333
-/qpid/trunk/qpid/java/test-profiles/log4j-test.xml:1072051-1185907
Modified: qpid/branches/QPID-2519/java/test-profiles/test-provider.properties
URL: http://svn.apache.org/viewvc/qpid/branches/QPID-2519/java/test-profiles/test-provider.properties?rev=1187150&r1=1187149&r2=1187150&view=diff
==============================================================================
--- qpid/branches/QPID-2519/java/test-profiles/test-provider.properties (original)
+++ qpid/branches/QPID-2519/java/test-profiles/test-provider.properties Fri Oct 21 01:19:00 2011
@@ -30,12 +30,16 @@ test.port.alt.ssl=25671
connectionfactory.default = amqp://username:password@clientid/test?brokerlist='tcp://localhost:${test.port}'
connectionfactory.default.ssl = amqp://username:password@clientid/test?brokerlist='tcp://localhost:${test.port.ssl}?ssl='true''
+connectionfactory.default.vm = amqp://username:password@clientid/test?brokerlist='vm://:1'
connectionfactory.failover = amqp://username:password@clientid/test?brokerlist='tcp://localhost:${test.port.alt};tcp://localhost:${test.port}'&sync_ack='true'&sync_publish='all'&failover='roundrobin?cyclecount='20''
connectionfactory.failover.ssl = amqp://username:password@clientid/test?brokerlist='tcp://localhost:${test.port.alt.ssl}?ssl='true';tcp://localhost:${test.port.ssl}?ssl='true''&sync_ack='true'&sync_publish='all'&failover='roundrobin?cyclecount='20''
+connectionfactory.failover.vm = amqp://username:password@clientid/test?brokerlist='vm://:2;vm://:1'&failover='roundrobin?cyclecount='20''
connectionfactory.connection1 = amqp://username:password@clientid/test?brokerlist='tcp://localhost:${test.port}'
connectionfactory.connection2 = amqp://username:password@clientid/test?brokerlist='tcp://localhost:${test.port.alt}'
+connectionfactory.connection1.vm = amqp://username:password@clientid/test?brokerlist='vm://:1'
+connectionfactory.connection2.vm = amqp://username:password@clientid/test?brokerlist='vm://:2'
queue.MyQueue = example.MyQueue
Propchange: qpid/branches/QPID-2519/java/test-profiles/test-provider.properties
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 21 01:19:00 2011
@@ -1,5 +1,3 @@
/incubator/qpid/trunk/qpid/java/test-profiles/test-provider.properties:443187-726139
/qpid/branches/java-broker-0-10/qpid/java/test-profiles/test-provider.properties:795950-829653
/qpid/branches/java-network-refactor/qpid/java/test-profiles/test-provider.properties:805429-821809
-/qpid/branches/qpid-2935/qpid/java/test-profiles/test-provider.properties:1061302-1072333
-/qpid/trunk/qpid/java/test-profiles/test-provider.properties:1072051-1185907
Propchange: qpid/branches/QPID-2519/java/test-profiles/test_resources/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 21 01:19:00 2011
@@ -1,5 +1,3 @@
/incubator/qpid/trunk/qpid/java/test-profiles/test_resources:443187-726139
/qpid/branches/java-broker-0-10/qpid/java/test-profiles/test_resources:795950-829653
/qpid/branches/java-network-refactor/qpid/java/test-profiles/test_resources:805429-821809
-/qpid/branches/qpid-2935/qpid/java/test-profiles/test_resources:1061302-1072333
-/qpid/trunk/qpid/java/test-profiles/test_resources:1072051-1185907
Modified: qpid/branches/QPID-2519/java/tools/bin/qpid-bench
URL: http://svn.apache.org/viewvc/qpid/branches/QPID-2519/java/tools/bin/qpid-bench?rev=1187150&r1=1187149&r2=1187150&view=diff
==============================================================================
--- qpid/branches/QPID-2519/java/tools/bin/qpid-bench (original)
+++ qpid/branches/QPID-2519/java/tools/bin/qpid-bench Fri Oct 21 01:19:00 2011
@@ -18,6 +18,18 @@
# under the License.
#
-. check-qpid-java-env
+if [ -z "$QPID_HOME" ]; then
+ export QPID_HOME=$(dirname $(dirname $(readlink -f $0)))
+ export PATH=${PATH}:${QPID_HOME}/bin
+fi
-$JAVA -cp $CLASSPATH -server $JAVA_MEM $LOG_CONFIG org.apache.qpid.tools.QpidBench "$@"
+# Set classpath to include Qpid jar with all required jars in manifest
+QPID_LIBS=$QPID_HOME/lib/qpid-all.jar
+
+# Set other variables used by the qpid-run script before calling
+export JAVA=java \
+ JAVA_VM=-server \
+ JAVA_MEM=-Xmx1024m \
+ QPID_CLASSPATH=$QPID_LIBS
+
+. qpid-run org.apache.qpid.tools.QpidBench "$@"
Propchange: qpid/branches/QPID-2519/java/tools/bin/qpid-bench
('svn:executable' removed)
Modified: qpid/branches/QPID-2519/java/tools/bin/qpid-python-testkit
URL: http://svn.apache.org/viewvc/qpid/branches/QPID-2519/java/tools/bin/qpid-python-testkit?rev=1187150&r1=1187149&r2=1187150&view=diff
==============================================================================
--- qpid/branches/QPID-2519/java/tools/bin/qpid-python-testkit (original)
+++ qpid/branches/QPID-2519/java/tools/bin/qpid-python-testkit Fri Oct 21 01:19:00 2011
@@ -22,12 +22,9 @@
# via the python test runner. The defaults are set for a running
# from an svn checkout
-. check-qpid-java-env
+. ./set-testkit-env.sh
export PYTHONPATH=./:$PYTHONPATH
-echo $PYTHONPATH
-if [ "$OUTDIR" = "" ] ; then
- OUTDIR=$PWD
-fi
-testdir=$OUTDIR/testkit-out-`date +%F-%H-%M-%S`
-qpid-python-test -m testkit -DOUTDIR=$testdir"$@"
+rm -rf $OUTDIR
+qpid-python-test -DOUTDIR=$OUTDIR -m testkit "$@"
+
Propchange: qpid/branches/QPID-2519/java/tools/etc/test.log4j
------------------------------------------------------------------------------
--- svn:mergeinfo (added)
+++ svn:mergeinfo Fri Oct 21 01:19:00 2011
@@ -0,0 +1,7 @@
+/qpid/branches/0.5.x-dev/qpid/java/tools/etc/test.log4j:886720-886722,887145,892761,894875,916304,916325,930288,931179
+/qpid/branches/0.5.x-dev/tools/etc/test.log4j:886720-886722
+/qpid/branches/java-broker-0-10/qpid/java/tools/etc/test.log4j:795950-829653
+/qpid/branches/java-network-refactor/qpid/java/tools/etc/test.log4j:805429-821809
+/qpid/branches/qpid-2935/qpid/java/tools/etc/test.log4j:1061302-1072333
+/qpid/trunk/qpid/java/tools/etc/test.log4j:1072051-1185907
+/qpid/trunk/qpid/tools/etc/test.log4j:796646-796653
Modified: qpid/branches/QPID-2519/java/tools/src/main/java/org/apache/qpid/tools/LatencyTest.java
URL: http://svn.apache.org/viewvc/qpid/branches/QPID-2519/java/tools/src/main/java/org/apache/qpid/tools/LatencyTest.java?rev=1187150&r1=1187149&r2=1187150&view=diff
==============================================================================
--- qpid/branches/QPID-2519/java/tools/src/main/java/org/apache/qpid/tools/LatencyTest.java (original)
+++ qpid/branches/QPID-2519/java/tools/src/main/java/org/apache/qpid/tools/LatencyTest.java Fri Oct 21 01:19:00 2011
@@ -77,7 +77,7 @@ public class LatencyTest extends PerfBas
public LatencyTest()
{
- super("");
+ super();
warmedUp = lock.newCondition();
testCompleted = lock.newCondition();
// Storing the following two for efficiency
@@ -314,7 +314,7 @@ public class LatencyTest extends PerfBas
public static void main(String[] args)
{
- final LatencyTest latencyTest = new LatencyTest();
+ final LatencyTest latencyTest = new LatencyTest();
Runnable r = new Runnable()
{
public void run()
@@ -334,16 +334,16 @@ public class LatencyTest extends PerfBas
}
}
};
-
+
Thread t;
try
{
- t = Threading.getThreadFactory().createThread(r);
+ t = Threading.getThreadFactory().createThread(r);
}
catch(Exception e)
{
throw new Error("Error creating latency test thread",e);
}
- t.start();
+ t.start();
}
-}
+}
\ No newline at end of file
---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project: http://qpid.apache.org
Use/Interact: mailto:commits-subscribe@qpid.apache.org