From 637a4af1ff36761f5bf57fa434cfe2b699f53a3a Mon Sep 17 00:00:00 2001 From: Robert Gemmell Date: Wed, 7 Sep 2011 11:56:10 +0000 Subject: QPID-3467: replace the 'connection id' with the Username of the logged in user for the ManagementActor, since the value for the connection id was arrived at using an incorrect assumption that the id number in the thread name for a particular RMI thread is specific to a given JMX connection when it isnt. Applied patch from Oleksandr Rudyy git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@1166134 13f79535-47bb-0310-9956-ffa450edef68 --- .../management/jmx/ManagementActorLoggingTest.java | 55 ---------------------- 1 file changed, 55 deletions(-) (limited to 'qpid/java/systests') diff --git a/qpid/java/systests/src/main/java/org/apache/qpid/management/jmx/ManagementActorLoggingTest.java b/qpid/java/systests/src/main/java/org/apache/qpid/management/jmx/ManagementActorLoggingTest.java index 19657ef396..2864d8e994 100644 --- a/qpid/java/systests/src/main/java/org/apache/qpid/management/jmx/ManagementActorLoggingTest.java +++ b/qpid/java/systests/src/main/java/org/apache/qpid/management/jmx/ManagementActorLoggingTest.java @@ -66,61 +66,6 @@ public class ManagementActorLoggingTest extends AbstractTestLogging super.tearDown(); } - /** - * Description: - * When a JMX Management connection is made then this will be logged out. - * - * Input: - * - * 1. Running Broker - * 2. Connect Management client via JMX - * Output: - * - * MNG-1007 : Open - * - * Validation Steps: - * 1. The MNG ID is correct - * 2. The user is correct - * - * On connection close a MNG-1008 is expected - * - * * MNG-1008 : Close - * - * Validation Steps: - * 1. The MNG ID is correct - * - * @throws java.io.IOException - if there is a problem reseting the log monitor - */ - public void testJMXManagementConsoleConnection() throws IOException - { - List results = waitAndFindMatches("MNG-1007"); - - assertEquals("Unexpected Management Connection count", 1, results.size()); - - String log = getLogMessage(results, 0); - - validateMessageID("MNG-1007", log); - - assertTrue("User not in log message:" + log, log.endsWith(USER)); - // Extract the id from the log string - // MESSAGE [mng:1(rmi://169.24.29.116)] MNG-1007 : Open : User admin - int connectionID = Integer.parseInt(fromActor(getLog(results.get(0))).charAt(4) + ""); - - results = findMatches("MNG-1008"); - - assertEquals("Unexpected Management Connection close count", 0, results.size()); - - _jmxUtils.close(); - _closed = true; - - results = waitAndFindMatches("MNG-1008"); - - assertEquals("Unexpected Management Connection count", 1, results.size()); - - assertEquals("Close does not have same id as open,", connectionID, - Integer.parseInt(fromActor(getLog(results.get(0))).charAt(4) + "")); - } - /** * Description: * When a connected client has its connection closed via the Management Console this will be logged as a CON-1002 message. -- cgit v1.2.1