Search in sources :

Example 1 with UnitTestMessageLogger

use of org.apache.qpid.server.logging.UnitTestMessageLogger in project qpid-broker-j by apache.

the class AbstractTestLogSubject method performLog.

protected List<Object> performLog(boolean statusUpdatesEnabled) {
    if (_subject == null) {
        throw new NullPointerException("LogSubject has not been set");
    }
    UnitTestMessageLogger logger = new UnitTestMessageLogger(statusUpdatesEnabled);
    EventLogger eventLogger = new EventLogger(logger);
    eventLogger.message(_subject, new LogMessage() {

        @Override
        public String toString() {
            return "<Log Message>";
        }

        @Override
        public String getLogHierarchy() {
            return "test.hierarchy";
        }
    });
    return logger.getLogMessages();
}
Also used : EventLogger(org.apache.qpid.server.logging.EventLogger) LogMessage(org.apache.qpid.server.logging.LogMessage) UnitTestMessageLogger(org.apache.qpid.server.logging.UnitTestMessageLogger)

Example 2 with UnitTestMessageLogger

use of org.apache.qpid.server.logging.UnitTestMessageLogger in project qpid-broker-j by apache.

the class BaseActorTestCase method setUp.

@Override
public void setUp() throws Exception {
    super.setUp();
    _rawLogger = new UnitTestMessageLogger(_statusUpdatesEnabled);
    _eventLogger = new EventLogger(_rawLogger);
}
Also used : EventLogger(org.apache.qpid.server.logging.EventLogger) UnitTestMessageLogger(org.apache.qpid.server.logging.UnitTestMessageLogger)

Example 3 with UnitTestMessageLogger

use of org.apache.qpid.server.logging.UnitTestMessageLogger in project qpid-broker-j by apache.

the class AbstractTestMessages method setUp.

@Override
public void setUp() throws Exception {
    super.setUp();
    BrokerTestHelper.setUp();
    _logger = new UnitTestMessageLogger();
    _eventLogger = new EventLogger(_logger);
}
Also used : EventLogger(org.apache.qpid.server.logging.EventLogger) UnitTestMessageLogger(org.apache.qpid.server.logging.UnitTestMessageLogger)

Example 4 with UnitTestMessageLogger

use of org.apache.qpid.server.logging.UnitTestMessageLogger in project qpid-broker-j by apache.

the class RuleBasedAccessControlTest method setUp.

@Override
public void setUp() throws Exception {
    super.setUp();
    _messageLogger = new UnitTestMessageLogger();
    _eventLogger = new EventLogger(_messageLogger);
    _plugin = null;
}
Also used : EventLogger(org.apache.qpid.server.logging.EventLogger) UnitTestMessageLogger(org.apache.qpid.server.logging.UnitTestMessageLogger)

Aggregations

EventLogger (org.apache.qpid.server.logging.EventLogger)4 UnitTestMessageLogger (org.apache.qpid.server.logging.UnitTestMessageLogger)4 LogMessage (org.apache.qpid.server.logging.LogMessage)1