You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@qpid.apache.org by rg...@apache.org on 2009/10/05 13:11:14 UTC
svn commit: r821755 [1/3] - in /qpid/branches/java-broker-0-10/qpid/java: ./
broker/ broker/bin/ broker/etc/ broker/src/main/java/org/apache/qpid/server/
broker/src/main/java/org/apache/qpid/server/exchange/
broker/src/main/java/org/apache/qpid/server/...
Author: rgodfrey
Date: Mon Oct 5 11:11:05 2009
New Revision: 821755
URL: http://svn.apache.org/viewvc?rev=821755&view=rev
Log:
Merged from trunk up to r802129
Added:
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/logging/StartupRootMessageLogger.java
- copied unchanged from r802129, qpid/trunk/qpid/java/broker/src/main/java/org/apache/qpid/server/logging/StartupRootMessageLogger.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/logging/actors/BrokerActor.java
- copied unchanged from r802129, qpid/trunk/qpid/java/broker/src/main/java/org/apache/qpid/server/logging/actors/BrokerActor.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/logging/actors/SubscriptionActor.java
- copied unchanged from r802129, qpid/trunk/qpid/java/broker/src/main/java/org/apache/qpid/server/logging/actors/SubscriptionActor.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/logging/rawloggers/SystemOutMessageLogger.java
- copied unchanged from r802129, qpid/trunk/qpid/java/broker/src/main/java/org/apache/qpid/server/logging/rawloggers/SystemOutMessageLogger.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/logging/subjects/MessageStoreLogSubject.java
- copied unchanged from r802129, qpid/trunk/qpid/java/broker/src/main/java/org/apache/qpid/server/logging/subjects/MessageStoreLogSubject.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/store/AbstractMessageStore.java
- copied unchanged from r802129, qpid/trunk/qpid/java/broker/src/main/java/org/apache/qpid/server/store/AbstractMessageStore.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/transport/QpidAcceptor.java
- copied unchanged from r802129, qpid/trunk/qpid/java/broker/src/main/java/org/apache/qpid/server/transport/QpidAcceptor.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/logging/actors/SubscriptionActorTest.java
- copied unchanged from r802129, qpid/trunk/qpid/java/broker/src/test/java/org/apache/qpid/server/logging/actors/SubscriptionActorTest.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/logging/actors/TestLogActor.java
- copied unchanged from r802129, qpid/trunk/qpid/java/broker/src/test/java/org/apache/qpid/server/logging/actors/TestLogActor.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/util/NullApplicationRegistry.java
- copied unchanged from r802129, qpid/trunk/qpid/java/broker/src/test/java/org/apache/qpid/server/util/NullApplicationRegistry.java
qpid/branches/java-broker-0-10/qpid/java/management/eclipse-plugin/icons/configuration_management.gif
- copied unchanged from r802129, qpid/trunk/qpid/java/management/eclipse-plugin/icons/configuration_management.gif
qpid/branches/java-broker-0-10/qpid/java/management/eclipse-plugin/icons/logging_management.gif
- copied unchanged from r802129, qpid/trunk/qpid/java/management/eclipse-plugin/icons/logging_management.gif
qpid/branches/java-broker-0-10/qpid/java/management/eclipse-plugin/icons/server_information.gif
- copied unchanged from r802129, qpid/trunk/qpid/java/management/eclipse-plugin/icons/server_information.gif
qpid/branches/java-broker-0-10/qpid/java/management/eclipse-plugin/icons/user_management.gif
- copied unchanged from r802129, qpid/trunk/qpid/java/management/eclipse-plugin/icons/user_management.gif
qpid/branches/java-broker-0-10/qpid/java/management/eclipse-plugin/icons/virtualhost_manager.gif
- copied unchanged from r802129, qpid/trunk/qpid/java/management/eclipse-plugin/icons/virtualhost_manager.gif
qpid/branches/java-broker-0-10/qpid/java/systests/src/main/java/org/apache/qpid/server/logging/BindingLoggingTest.java
- copied unchanged from r802129, qpid/trunk/qpid/java/systests/src/main/java/org/apache/qpid/server/logging/BindingLoggingTest.java
qpid/branches/java-broker-0-10/qpid/java/systests/src/main/java/org/apache/qpid/server/logging/BrokerLoggingTest.java
- copied unchanged from r802129, qpid/trunk/qpid/java/systests/src/main/java/org/apache/qpid/server/logging/BrokerLoggingTest.java
qpid/branches/java-broker-0-10/qpid/java/systests/src/main/java/org/apache/qpid/server/logging/DerbyMessageStoreLoggingTest.java
- copied unchanged from r802129, qpid/trunk/qpid/java/systests/src/main/java/org/apache/qpid/server/logging/DerbyMessageStoreLoggingTest.java
qpid/branches/java-broker-0-10/qpid/java/systests/src/main/java/org/apache/qpid/server/logging/DurableQueueLoggingTest.java
- copied unchanged from r802129, qpid/trunk/qpid/java/systests/src/main/java/org/apache/qpid/server/logging/DurableQueueLoggingTest.java
qpid/branches/java-broker-0-10/qpid/java/systests/src/main/java/org/apache/qpid/server/logging/ExchangeLoggingTest.java
- copied unchanged from r802129, qpid/trunk/qpid/java/systests/src/main/java/org/apache/qpid/server/logging/ExchangeLoggingTest.java
qpid/branches/java-broker-0-10/qpid/java/systests/src/main/java/org/apache/qpid/server/logging/ManagementLoggingTest.java
- copied unchanged from r802129, qpid/trunk/qpid/java/systests/src/main/java/org/apache/qpid/server/logging/ManagementLoggingTest.java
qpid/branches/java-broker-0-10/qpid/java/systests/src/main/java/org/apache/qpid/server/logging/MemoryMessageStoreLoggingTest.java
- copied unchanged from r802129, qpid/trunk/qpid/java/systests/src/main/java/org/apache/qpid/server/logging/MemoryMessageStoreLoggingTest.java
qpid/branches/java-broker-0-10/qpid/java/systests/src/main/java/org/apache/qpid/server/logging/QueueLoggingTest.java
- copied unchanged from r802129, qpid/trunk/qpid/java/systests/src/main/java/org/apache/qpid/server/logging/QueueLoggingTest.java
qpid/branches/java-broker-0-10/qpid/java/systests/src/main/java/org/apache/qpid/server/logging/SubscriptionLoggingTest.java
- copied unchanged from r802129, qpid/trunk/qpid/java/systests/src/main/java/org/apache/qpid/server/logging/SubscriptionLoggingTest.java
qpid/branches/java-broker-0-10/qpid/java/systests/src/main/java/org/apache/qpid/server/logging/TransientQueueLoggingTest.java
- copied unchanged from r802129, qpid/trunk/qpid/java/systests/src/main/java/org/apache/qpid/server/logging/TransientQueueLoggingTest.java
Removed:
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/logging/subjects/MessagesStoreLogSubject.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/util/NullApplicationRegistry.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/logging/actors/TestBlankActor.java
qpid/branches/java-broker-0-10/qpid/java/management/eclipse-plugin/icons/Thumbs.db
Modified:
qpid/branches/java-broker-0-10/qpid/java/ (props changed)
qpid/branches/java-broker-0-10/qpid/java/broker/ (props changed)
qpid/branches/java-broker-0-10/qpid/java/broker/bin/ (props changed)
qpid/branches/java-broker-0-10/qpid/java/broker/etc/config-systests-derby.xml
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/Main.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/exchange/AbstractExchange.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/filter/JMSSelectorFilter.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/filter/NoConsumerFilter.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/filter/SimpleFilterManager.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/logging/actors/CurrentActor.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/management/ (props changed)
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/management/JMXManagedObjectRegistry.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/queue/ (props changed)
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/queue/ExchangeBinding.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/queue/ExchangeBindings.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/queue/SimpleAMQQueue.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/registry/ApplicationRegistry.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/registry/ConfigurationFileApplicationRegistry.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/registry/IApplicationRegistry.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/store/DerbyMessageStore.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/store/MemoryMessageStore.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/subscription/Subscription.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/subscription/SubscriptionImpl.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/subscription/Subscription_0_10.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/AMQBrokerManagerMBeanTest.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/ExtractResendAndRequeueTest.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/ack/TxAckTest.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/configuration/ServerConfigurationTest.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/configuration/VirtualHostConfigurationTest.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/exchange/DestWildExchangeTest.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/exchange/ExchangeMBeanTest.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/exchange/HeadersExchangeTest.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/logging/actors/AMQPChannelActorTest.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/logging/actors/AMQPConnectionActorTest.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/logging/actors/CurrentActorTest.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/logging/messages/AbstractTestMessages.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/logging/subjects/AbstractTestLogSubject.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/logging/subjects/MessageStoreLogSubjectTest.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/logging/subjects/SubscriptionLogSubjectTest.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/protocol/AMQProtocolSessionMBeanTest.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/protocol/MaxChannelsTest.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/queue/AMQQueueAlertTest.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/queue/AMQQueueFactoryTest.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/queue/AMQQueueMBeanTest.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/queue/AckTest.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/queue/MockAMQQueue.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/queue/SimpleAMQQueueTest.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/queue/SimpleAMQQueueThreadPoolTest.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/registry/ApplicationRegistryShutdownTest.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/security/access/ACLManagerTest.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/security/access/PrincipalPermissionsTest.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/security/access/plugins/network/FirewallPluginTest.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/store/MessageStoreTest.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/subscription/MockSubscription.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/util/InternalBrokerBaseCase.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/test/java/org/apache/qpid/server/util/TestApplicationRegistry.java
qpid/branches/java-broker-0-10/qpid/java/broker/src/velocity/templates/org/apache/qpid/server/logging/messages/LogMessages.vm
qpid/branches/java-broker-0-10/qpid/java/management/common/src/main/java/org/apache/qpid/management/common/mbeans/ConfigurationManagement.java (props changed)
qpid/branches/java-broker-0-10/qpid/java/management/common/src/main/java/org/apache/qpid/management/common/mbeans/LoggingManagement.java (props changed)
qpid/branches/java-broker-0-10/qpid/java/management/common/src/main/java/org/apache/qpid/management/common/mbeans/ManagedBroker.java (props changed)
qpid/branches/java-broker-0-10/qpid/java/management/common/src/main/java/org/apache/qpid/management/common/mbeans/ManagedConnection.java (props changed)
qpid/branches/java-broker-0-10/qpid/java/management/common/src/main/java/org/apache/qpid/management/common/mbeans/ManagedExchange.java (props changed)
qpid/branches/java-broker-0-10/qpid/java/management/common/src/main/java/org/apache/qpid/management/common/mbeans/ManagedQueue.java (props changed)
qpid/branches/java-broker-0-10/qpid/java/management/common/src/main/java/org/apache/qpid/management/common/mbeans/UserManagement.java (props changed)
qpid/branches/java-broker-0-10/qpid/java/management/common/src/main/java/org/apache/qpid/management/common/mbeans/annotations/MBeanAttribute.java (props changed)
qpid/branches/java-broker-0-10/qpid/java/management/common/src/main/java/org/apache/qpid/management/common/mbeans/annotations/MBeanConstructor.java (props changed)
qpid/branches/java-broker-0-10/qpid/java/management/common/src/main/java/org/apache/qpid/management/common/mbeans/annotations/MBeanDescription.java (props changed)
qpid/branches/java-broker-0-10/qpid/java/management/common/src/main/java/org/apache/qpid/management/common/mbeans/annotations/MBeanOperation.java (props changed)
qpid/branches/java-broker-0-10/qpid/java/management/common/src/main/java/org/apache/qpid/management/common/mbeans/annotations/MBeanOperationParameter.java (props changed)
qpid/branches/java-broker-0-10/qpid/java/management/eclipse-plugin/build.xml
qpid/branches/java-broker-0-10/qpid/java/management/eclipse-plugin/icons/qpidConnections.gif
qpid/branches/java-broker-0-10/qpid/java/management/eclipse-plugin/icons/refresh.gif
qpid/branches/java-broker-0-10/qpid/java/management/eclipse-plugin/plugin.xml
qpid/branches/java-broker-0-10/qpid/java/management/eclipse-plugin/src/ (props changed)
qpid/branches/java-broker-0-10/qpid/java/management/eclipse-plugin/src/main/java/org/apache/qpid/management/ui/ApplicationRegistry.java
qpid/branches/java-broker-0-10/qpid/java/management/eclipse-plugin/src/main/java/org/apache/qpid/management/ui/Constants.java
qpid/branches/java-broker-0-10/qpid/java/management/eclipse-plugin/src/main/java/org/apache/qpid/management/ui/views/NavigationView.java
qpid/branches/java-broker-0-10/qpid/java/management/eclipse-plugin/src/main/java/org/apache/qpid/management/ui/views/NotificationsTabControl.java
qpid/branches/java-broker-0-10/qpid/java/management/eclipse-plugin/src/main/java/org/apache/qpid/management/ui/views/VHNotificationsTabControl.java
qpid/branches/java-broker-0-10/qpid/java/management/eclipse-plugin/src/main/java/org/apache/qpid/management/ui/views/queue/QueueOperationsTabControl.java
qpid/branches/java-broker-0-10/qpid/java/management/eclipse-plugin/src/main/java/org/apache/qpid/management/ui/views/type/ConnectionTypeTabControl.java (props changed)
qpid/branches/java-broker-0-10/qpid/java/management/eclipse-plugin/src/main/java/org/apache/qpid/management/ui/views/type/ExchangeTypeTabControl.java (props changed)
qpid/branches/java-broker-0-10/qpid/java/management/eclipse-plugin/src/main/java/org/apache/qpid/management/ui/views/type/MBeanTypeTabControl.java (props changed)
qpid/branches/java-broker-0-10/qpid/java/management/eclipse-plugin/src/main/java/org/apache/qpid/management/ui/views/type/QueueTypeTabControl.java (props changed)
qpid/branches/java-broker-0-10/qpid/java/management/eclipse-plugin/src/main/resources/macosx/Contents/MacOS/qpidmc (props changed)
qpid/branches/java-broker-0-10/qpid/java/management/eclipse-plugin/src/test/java/org/apache/qpid/management/ui/ManagementConsoleTest.java
qpid/branches/java-broker-0-10/qpid/java/module.xml
qpid/branches/java-broker-0-10/qpid/java/systests/src/main/java/org/apache/qpid/client/AMQQueueDeferredOrderingTest.java
qpid/branches/java-broker-0-10/qpid/java/systests/src/main/java/org/apache/qpid/server/failover/FailoverMethodTest.java
qpid/branches/java-broker-0-10/qpid/java/systests/src/main/java/org/apache/qpid/server/logging/AbstractTestLogging.java
qpid/branches/java-broker-0-10/qpid/java/systests/src/main/java/org/apache/qpid/server/logging/ChannelLoggingTest.java
qpid/branches/java-broker-0-10/qpid/java/systests/src/main/java/org/apache/qpid/server/logging/ConnectionLoggingTest.java
qpid/branches/java-broker-0-10/qpid/java/systests/src/main/java/org/apache/qpid/server/queue/QueueDepthWithSelectorTest.java
qpid/branches/java-broker-0-10/qpid/java/systests/src/main/java/org/apache/qpid/server/queue/SubscriptionTestHelper.java
qpid/branches/java-broker-0-10/qpid/java/systests/src/main/java/org/apache/qpid/server/security/acl/SimpleACLTest.java
qpid/branches/java-broker-0-10/qpid/java/systests/src/main/java/org/apache/qpid/test/framework/qpid/InVMBrokerDecorator.java
qpid/branches/java-broker-0-10/qpid/java/systests/src/main/java/org/apache/qpid/test/unit/basic/MultipleConnectionTest.java
qpid/branches/java-broker-0-10/qpid/java/systests/src/main/java/org/apache/qpid/test/unit/client/channelclose/ChannelCloseOkTest.java
qpid/branches/java-broker-0-10/qpid/java/systests/src/main/java/org/apache/qpid/test/unit/client/channelclose/ChannelCloseTest.java
qpid/branches/java-broker-0-10/qpid/java/systests/src/main/java/org/apache/qpid/test/unit/client/connection/CloseAfterConnectionFailureTest.java
qpid/branches/java-broker-0-10/qpid/java/systests/src/main/java/org/apache/qpid/test/utils/QpidTestCase.java
qpid/branches/java-broker-0-10/qpid/java/systests/src/main/java/org/apache/qpid/util/LogMonitor.java
qpid/branches/java-broker-0-10/qpid/java/test-profiles/010Excludes (props changed)
qpid/branches/java-broker-0-10/qpid/java/test-profiles/08Excludes (props changed)
qpid/branches/java-broker-0-10/qpid/java/test-profiles/08StandaloneExcludes (contents, props changed)
qpid/branches/java-broker-0-10/qpid/java/test-profiles/08TransientExcludes (props changed)
qpid/branches/java-broker-0-10/qpid/java/test-profiles/Excludes (contents, props changed)
qpid/branches/java-broker-0-10/qpid/java/test-profiles/XAExcludes (props changed)
qpid/branches/java-broker-0-10/qpid/java/test-profiles/cpp.ssl.excludes (props changed)
qpid/branches/java-broker-0-10/qpid/java/test-profiles/default.testprofile
qpid/branches/java-broker-0-10/qpid/java/test-profiles/java-derby.testprofile
qpid/branches/java-broker-0-10/qpid/java/test-profiles/java.testprofile
Propchange: qpid/branches/java-broker-0-10/qpid/java/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Mon Oct 5 11:11:05 2009
@@ -1,2 +1,2 @@
/qpid/trunk/qpid:796646-796653
-/qpid/trunk/qpid/java:796196-800440
+/qpid/trunk/qpid/java:796196-802129
Propchange: qpid/branches/java-broker-0-10/qpid/java/broker/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Mon Oct 5 11:11:05 2009
@@ -1,2 +1,2 @@
/qpid/branches/jmx_mc_gsoc09/qpid/java/broker:787599
-/qpid/trunk/qpid/java/broker:742626,743015,743028-743029,743304,743306,743311,743357,744113,747363,747367,747369-747370,747376,747783,747868-747870,747875,748561,748591,748641,748680,748686,749149,749282,749285,749315,749340,749572,753219-753220,753253,754934,754958,755256,757258,757270,758730,759097,760919,761721,762365,762992,763959,764026,764109,764140,764790,796196-800440
+/qpid/trunk/qpid/java/broker:742626,743015,743028-743029,743304,743306,743311,743357,744113,747363,747367,747369-747370,747376,747783,747868-747870,747875,748561,748591,748641,748680,748686,749149,749282,749285,749315,749340,749572,753219-753220,753253,754934,754958,755256,757258,757270,758730,759097,760919,761721,762365,762992,763959,764026,764109,764140,764790,796196-802129
Propchange: qpid/branches/java-broker-0-10/qpid/java/broker/bin/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Mon Oct 5 11:11:05 2009
@@ -1,2 +1,2 @@
/qpid/branches/0.5-release/qpid/java/broker/bin:757268
-/qpid/trunk/qpid/java/broker/bin:753219-753220,753253,758730,759097,760919,761721,762365,762992,763959,764026,764109,764140,764790,796196-800440
+/qpid/trunk/qpid/java/broker/bin:753219-753220,753253,758730,759097,760919,761721,762365,762992,763959,764026,764109,764140,764790,796196-802129
Modified: qpid/branches/java-broker-0-10/qpid/java/broker/etc/config-systests-derby.xml
URL: http://svn.apache.org/viewvc/qpid/branches/java-broker-0-10/qpid/java/broker/etc/config-systests-derby.xml?rev=821755&r1=821754&r2=821755&view=diff
==============================================================================
--- qpid/branches/java-broker-0-10/qpid/java/broker/etc/config-systests-derby.xml (original)
+++ qpid/branches/java-broker-0-10/qpid/java/broker/etc/config-systests-derby.xml Mon Oct 5 11:11:05 2009
@@ -96,6 +96,7 @@
<localhost>
<store>
<class>org.apache.qpid.server.store.DerbyMessageStore</class>
+ <environment-path>${work}/derbyDB/localhost-store</environment-path>
</store>
<housekeeping>
@@ -110,6 +111,7 @@
<development>
<store>
<class>org.apache.qpid.server.store.DerbyMessageStore</class>
+ <environment-path>${work}/derbyDB/development-store</environment-path>
</store>
</development>
</virtualhost>
@@ -119,6 +121,7 @@
<test>
<store>
<class>org.apache.qpid.server.store.DerbyMessageStore</class>
+ <environment-path>${work}/derbyDB/test-store</environment-path>
</store>
</test>
</virtualhost>
Modified: qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/Main.java
URL: http://svn.apache.org/viewvc/qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/Main.java?rev=821755&r1=821754&r2=821755&view=diff
==============================================================================
--- qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/Main.java (original)
+++ qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/Main.java Mon Oct 5 11:11:05 2009
@@ -20,14 +20,6 @@
*/
package org.apache.qpid.server;
-import java.io.File;
-import java.io.IOException;
-import java.net.BindException;
-import java.net.InetAddress;
-import java.net.InetSocketAddress;
-
-import javax.management.NotCompliantMBeanException;
-
import org.apache.commons.cli.CommandLine;
import org.apache.commons.cli.HelpFormatter;
import org.apache.commons.cli.Option;
@@ -54,7 +46,11 @@
import org.apache.qpid.server.configuration.ServerConfiguration;
import org.apache.qpid.server.configuration.management.ConfigurationManagementMBean;
import org.apache.qpid.server.information.management.ServerInformationMBean;
+import org.apache.qpid.server.logging.StartupRootMessageLogger;
+import org.apache.qpid.server.logging.actors.BrokerActor;
+import org.apache.qpid.server.logging.actors.CurrentActor;
import org.apache.qpid.server.logging.management.LoggingManagementMBean;
+import org.apache.qpid.server.logging.messages.BrokerMessages;
import org.apache.qpid.server.protocol.AMQPFastProtocolHandler;
import org.apache.qpid.server.protocol.AMQPProtocolProvider;
import org.apache.qpid.server.registry.ApplicationRegistry;
@@ -62,6 +58,13 @@
import org.apache.qpid.server.registry.IApplicationRegistry;
import org.apache.qpid.server.security.auth.manager.AuthenticationManager;
import org.apache.qpid.server.transport.ServerConnection;
+import org.apache.qpid.server.transport.QpidAcceptor;
+
+import java.io.File;
+import java.io.IOException;
+import java.net.BindException;
+import java.net.InetAddress;
+import java.net.InetSocketAddress;
/**
* Main entry point for AMQPD.
@@ -75,7 +78,7 @@
private static final String DEFAULT_CONFIG_FILE = "etc/config.xml";
- private static final String DEFAULT_LOG_CONFIG_FILENAME = "log4j.xml";
+ public static final String DEFAULT_LOG_CONFIG_FILENAME = "log4j.xml";
public static final String QPID_HOME = "QPID_HOME";
private static final int IPV4_ADDRESS_LENGTH = 4;
@@ -197,7 +200,9 @@
{
try
{
+ CurrentActor.set(new BrokerActor(new StartupRootMessageLogger()));
startup();
+ CurrentActor.remove();
}
catch (InitException e)
{
@@ -239,7 +244,7 @@
}
else
{
- System.out.println("Using configuration file " + configFile.getAbsolutePath());
+ CurrentActor.get().message(BrokerMessages.BRK_1006(configFile.getAbsolutePath()));
}
String logConfig = commandLine.getOptionValue("l");
@@ -274,75 +279,94 @@
updateManagementPort(serverConfig, commandLine.getOptionValue("m"));
ApplicationRegistry.initialise(config);
-
- configureLoggingManagementMBean(logConfigFile, logWatchTime);
-
- ConfigurationManagementMBean configMBean = new ConfigurationManagementMBean();
- configMBean.register();
-
- ServerInformationMBean sysInfoMBean =
- new ServerInformationMBean(QpidProperties.getBuildVersion(), QpidProperties.getReleaseVersion());
- sysInfoMBean.register();
-
- //fixme .. use QpidProperties.getVersionString when we have fixed the classpath issues
- // that are causing the broker build to pick up the wrong properties file and hence say
- // Starting Qpid Client
- _brokerLogger.info("Starting Qpid Broker " + QpidProperties.getReleaseVersion()
- + " build: " + QpidProperties.getBuildVersion());
-
- ByteBuffer.setUseDirectBuffers(serverConfig.getEnableDirectBuffers());
- // the MINA default is currently to use the pooled allocator although this may change in future
- // once more testing of the performance of the simple allocator has been done
- if (!serverConfig.getEnablePooledAllocator())
+ // We have already loaded the BrokerMessages class by this point so we
+ // need to refresh the locale setting incase we had a different value in
+ // the configuration.
+ BrokerMessages.reload();
+
+ // AR.initialise() sets its own actor so we now need to set the actor
+ // for the remainder of the startup
+ CurrentActor.set(new BrokerActor(config.getRootMessageLogger()));
+ try
{
- ByteBuffer.setAllocator(new FixedSizeByteBufferAllocator());
- }
+ configureLoggingManagementMBean(logConfigFile, logWatchTime);
- if(serverConfig.getUseBiasedWrites())
- {
- System.setProperty("org.apache.qpid.use_write_biased_pool","true");
- }
+ ConfigurationManagementMBean configMBean = new ConfigurationManagementMBean();
+ configMBean.register();
- int port = serverConfig.getPort();
+ ServerInformationMBean sysInfoMBean =
+ new ServerInformationMBean(QpidProperties.getBuildVersion(), QpidProperties.getReleaseVersion());
+ sysInfoMBean.register();
+
+ //fixme .. use QpidProperties.getVersionString when we have fixed the classpath issues
+ // that are causing the broker build to pick up the wrong properties file and hence say
+ // Starting Qpid Client
+ _brokerLogger.info("Starting Qpid Broker " + QpidProperties.getReleaseVersion()
+ + " build: " + QpidProperties.getBuildVersion());
- String portStr = commandLine.getOptionValue("p");
- if (portStr != null)
- {
- try
+ ByteBuffer.setUseDirectBuffers(serverConfig.getEnableDirectBuffers());
+
+ // the MINA default is currently to use the pooled allocator although this may change in future
+ // once more testing of the performance of the simple allocator has been done
+ if (!serverConfig.getEnablePooledAllocator())
{
- port = Integer.parseInt(portStr);
+ ByteBuffer.setAllocator(new FixedSizeByteBufferAllocator());
}
- catch (NumberFormatException e)
+
+ if (serverConfig.getUseBiasedWrites())
{
- throw new InitException("Invalid port: " + portStr, e);
+ System.setProperty("org.apache.qpid.use_write_biased_pool", "true");
}
- }
-
- bind(port, serverConfig);
+ int port = serverConfig.getPort();
- IApplicationRegistry appRegistry = ApplicationRegistry.getInstance();
+ String portStr = commandLine.getOptionValue("p");
+ if (portStr != null)
+ {
+ try
+ {
+ port = Integer.parseInt(portStr);
+ }
+ catch (NumberFormatException e)
+ {
+ throw new InitException("Invalid port: " + portStr, e);
+ }
+ }
- final ConnectionDelegate delegate =
- new org.apache.qpid.server.transport.ServerConnectionDelegate(appRegistry, "localhost");
+ bind(port, serverConfig);
+ // TODO - Fix to use a proper binding
+ int port_0_10 = port + 1;
- ConnectionBinding cb = new ConnectionBinding()
- {
- public Connection connection()
+ IApplicationRegistry appRegistry = ApplicationRegistry.getInstance();
+
+ final ConnectionDelegate delegate =
+ new org.apache.qpid.server.transport.ServerConnectionDelegate(appRegistry, "localhost");
+
+
+ ConnectionBinding cb = new ConnectionBinding()
{
- ServerConnection conn = new ServerConnection();
- conn.setConnectionDelegate(delegate);
- return conn;
- }
- };
+ public Connection connection()
+ {
+ ServerConnection conn = new ServerConnection();
+ conn.setConnectionDelegate(delegate);
+ return conn;
+ }
+ };
+
+ org.apache.qpid.transport.network.io.IoAcceptor ioa = new org.apache.qpid.transport.network.io.IoAcceptor
+ ("0.0.0.0", port_0_10, cb);
+ ioa.start();
+ }
+ finally
+ {
+ // Startup is complete so remove the AR initialised Startup actor
+ CurrentActor.remove();
+ }
+
- int port_0_10 = port + 1;
- org.apache.qpid.transport.network.io.IoAcceptor ioa = new org.apache.qpid.transport.network.io.IoAcceptor
- ("0.0.0.0", port_0_10, cb);
- ioa.start();
}
/**
@@ -415,7 +439,7 @@
bindAddress = new InetSocketAddress(InetAddress.getByAddress(parseIP(bindAddr)), port);
}
- bind(acceptor, bindAddress, handler, sconfig);
+ bind(new QpidAcceptor(acceptor,"TCP"), bindAddress, handler, sconfig);
//fixme qpid.AMQP should be using qpidproperties to get value
_brokerLogger.info("Qpid.AMQP listening on non-SSL address " + bindAddress);
@@ -427,7 +451,7 @@
try
{
- bind(acceptor, new InetSocketAddress(config.getSSLPort()), handler, sconfig);
+ bind(new QpidAcceptor(acceptor, "TCP/SSL"), new InetSocketAddress(config.getSSLPort()), handler, sconfig);
//fixme qpid.AMQP should be using qpidproperties to get value
_brokerLogger.info("Qpid.AMQP listening on SSL port " + config.getSSLPort());
@@ -442,6 +466,9 @@
//fixme qpid.AMQP should be using qpidproperties to get value
_brokerLogger.info("Qpid Broker Ready :" + QpidProperties.getReleaseVersion()
+ " build: " + QpidProperties.getBuildVersion());
+
+ CurrentActor.get().message(BrokerMessages.BRK_1004());
+
}
catch (Exception e)
{
@@ -461,9 +488,11 @@
*
* @throws IOException from the acceptor.bind command
*/
- private void bind(IoAcceptor acceptor, InetSocketAddress bindAddress, AMQPFastProtocolHandler handler, SocketAcceptorConfig sconfig) throws IOException
+ private void bind(QpidAcceptor acceptor, InetSocketAddress bindAddress, AMQPFastProtocolHandler handler, SocketAcceptorConfig sconfig) throws IOException
{
- acceptor.bind(bindAddress, handler, sconfig);
+ acceptor.getIoAcceptor().bind(bindAddress, handler, sconfig);
+
+ CurrentActor.get().message(BrokerMessages.BRK_1002(acceptor.toString(), bindAddress.getPort()));
ApplicationRegistry.getInstance().addAcceptor(bindAddress, acceptor);
}
@@ -506,6 +535,7 @@
{
if (logConfigFile.exists() && logConfigFile.canRead())
{
+ CurrentActor.get().message(BrokerMessages.BRK_1007(logConfigFile.getAbsolutePath()));
System.out.println("Configuring logger using configuration file " + logConfigFile.getAbsolutePath());
if (logWatchTime > 0)
{
Modified: qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/exchange/AbstractExchange.java
URL: http://svn.apache.org/viewvc/qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/exchange/AbstractExchange.java?rev=821755&r1=821754&r2=821755&view=diff
==============================================================================
--- qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/exchange/AbstractExchange.java (original)
+++ qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/exchange/AbstractExchange.java Mon Oct 5 11:11:05 2009
@@ -42,6 +42,10 @@
import org.apache.qpid.server.queue.AMQQueue;
import org.apache.qpid.server.registry.ApplicationRegistry;
import org.apache.qpid.server.virtualhost.VirtualHost;
+import org.apache.qpid.server.logging.actors.CurrentActor;
+import org.apache.qpid.server.logging.messages.ExchangeMessages;
+import org.apache.qpid.server.logging.subjects.ExchangeLogSubject;
+import org.apache.qpid.server.logging.LogSubject;
import java.util.Map;
@@ -64,6 +68,9 @@
*/
protected boolean _autoDelete;
+ //The logSubject for ths exchange
+ private LogSubject _logSubject;
+
/**
* Abstract MBean class. This has some of the methods implemented from
* management intrerface for exchanges. Any implementaion of an
@@ -163,6 +170,10 @@
_ticket = ticket;
_exchangeMbean = createMBean();
_exchangeMbean.register();
+ _logSubject = new ExchangeLogSubject(this, this.getVirtualHost());
+
+ // Log Exchange creation
+ CurrentActor.get().message(ExchangeMessages.EXH_1001(String.valueOf(getType()), String.valueOf(name), durable));
}
public boolean isDurable()
@@ -186,6 +197,8 @@
{
_exchangeMbean.unregister();
}
+
+ CurrentActor.get().message(_logSubject, ExchangeMessages.EXH_1002());
}
public String toString()
Modified: qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/filter/JMSSelectorFilter.java
URL: http://svn.apache.org/viewvc/qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/filter/JMSSelectorFilter.java?rev=821755&r1=821754&r2=821755&view=diff
==============================================================================
--- qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/filter/JMSSelectorFilter.java (original)
+++ qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/filter/JMSSelectorFilter.java Mon Oct 5 11:11:05 2009
@@ -53,4 +53,10 @@
{
return _selector;
}
+
+ @Override
+ public String toString()
+ {
+ return "JMSSelector("+_selector+")";
+ }
}
Modified: qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/filter/NoConsumerFilter.java
URL: http://svn.apache.org/viewvc/qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/filter/NoConsumerFilter.java?rev=821755&r1=821754&r2=821755&view=diff
==============================================================================
--- qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/filter/NoConsumerFilter.java (original)
+++ qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/filter/NoConsumerFilter.java Mon Oct 5 11:11:05 2009
@@ -39,4 +39,10 @@
return true;
}
+ @Override
+ public String toString()
+ {
+ return "NoConsumer";
+ }
+
}
Modified: qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/filter/SimpleFilterManager.java
URL: http://svn.apache.org/viewvc/qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/filter/SimpleFilterManager.java?rev=821755&r1=821754&r2=821755&view=diff
==============================================================================
--- qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/filter/SimpleFilterManager.java (original)
+++ qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/filter/SimpleFilterManager.java Mon Oct 5 11:11:05 2009
@@ -24,7 +24,6 @@
import org.apache.log4j.Logger;
import org.apache.qpid.AMQException;
-import org.apache.qpid.server.queue.AMQMessage;
import org.apache.qpid.server.queue.Filterable;
public class SimpleFilterManager implements FilterManager
@@ -32,6 +31,7 @@
private final Logger _logger = Logger.getLogger(SimpleFilterManager.class);
private final ConcurrentLinkedQueue<MessageFilter> _filters;
+ private String _toString = "";
public SimpleFilterManager()
{
@@ -42,11 +42,13 @@
public void add(MessageFilter filter)
{
_filters.add(filter);
+ updateStringValue();
}
public void remove(MessageFilter filter)
{
_filters.remove(filter);
+ updateStringValue();
}
public boolean allAllow(Filterable msg)
@@ -65,4 +67,28 @@
{
return !_filters.isEmpty();
}
+
+
+ @Override
+ public String toString()
+ {
+ return _toString;
+ }
+
+ private void updateStringValue()
+ {
+ StringBuilder toString = new StringBuilder();
+ for (MessageFilter filter : _filters)
+ {
+ toString.append(filter.toString());
+ toString.append(",");
+ }
+
+ if (_filters.size() > 0)
+ {
+ //Remove the last ','
+ toString.deleteCharAt(toString.length()-1);
+ }
+ _toString = toString.toString();
+ }
}
Modified: qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/logging/actors/CurrentActor.java
URL: http://svn.apache.org/viewvc/qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/logging/actors/CurrentActor.java?rev=821755&r1=821754&r2=821755&view=diff
==============================================================================
--- qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/logging/actors/CurrentActor.java (original)
+++ qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/logging/actors/CurrentActor.java Mon Oct 5 11:11:05 2009
@@ -25,28 +25,82 @@
import java.util.LinkedList;
import java.util.Deque;
+/**
+ * The CurrentActor is a ThreadLocal wrapper that allows threads in the broker
+ * to retrieve an actor to perform logging. This approach is used so for two
+ * reasons:
+ * 1) We do not have to pass a logging actor around the system
+ * 2) We can set new actors at the point we have enough information. i.e.
+ * - Set a low level ConnectionActor when processing bytes from the wire.
+ * - Set a ChannelActor when we are processing the frame
+ * - Set a SubscriptionActor when we are handling the subscription.
+ *
+ * The code performing the logging need not worry about what type of actor is
+ * currently set so can perform its logging. The resulting log entry though will
+ * contain customised details from the the currently set Actor.
+ *
+ * The Actor model also allows the pre-creation of fixed messages so the
+ * performance impact of the additional logging data is minimised.
+ *
+ * This class does not perform any checks to ensure that there is an Actor set
+ * when calling remove or get. As a result the application developer must ensure
+ * that they have called set before they attempt to use the actor via get or
+ * remove the set actor.
+ *
+ * The checking of the return via get should not be done as the logging is
+ * desired. It is preferable to cause the NullPointerException to highlight the
+ * programming error rather than miss a log message.
+ *
+ * The same is true for the remove. A NPE will occur if no set has been called
+ * highlighting the programming error.
+ *
+ */
public class CurrentActor
{
+ /**
+ * The ThreadLocal variable with initialiser
+ */
private static final ThreadLocal<Deque<LogActor>> _currentActor = new ThreadLocal<Deque<LogActor>>()
{
+ // Initialise the CurrentActor to be an empty List
protected Deque<LogActor> initialValue()
{
return new LinkedList<LogActor>();
}
};
+ /**
+ * Set a new LogActor to be the Current Actor
+ *
+ * This pushes the Actor in to the LIFO Queue
+ *
+ * @param actor The new LogActor
+ */
public static void set(LogActor actor)
{
Deque<LogActor> stack = _currentActor.get();
stack.addFirst(actor);
}
+ /**
+ * Remove the current LogActor.
+ *
+ * Calling remove without calling set will result in a NoSuchElementException.
+ *
+ */
public static void remove()
{
Deque<LogActor> stack = _currentActor.get();
- stack.remove();
+ stack.removeFirst();
}
+ /**
+ * Return the current head of the list of LogActors.
+ *
+ * If there has been no set call then this will return Null.
+ *
+ * @return Current LogActor
+ */
public static LogActor get()
{
return _currentActor.get().peek();
Propchange: qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/management/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Mon Oct 5 11:11:05 2009
@@ -1,3 +1,3 @@
/qpid/branches/0.5-release/qpid/java/broker/src/main/java/org/apache/qpid/server/management:757268
/qpid/branches/jmx_mc_gsoc09/qpid/java/broker/src/main/java/org/apache/qpid/server/management:787599
-/qpid/trunk/qpid/java/broker/src/main/java/org/apache/qpid/server/management:753219-753220,753253,758730,759097,760919,761721,762365,762992,763959,764026,764109,764140,764790,796196-800440
+/qpid/trunk/qpid/java/broker/src/main/java/org/apache/qpid/server/management:753219-753220,753253,758730,759097,760919,761721,762365,762992,763959,764026,764109,764140,764790,796196-802129
Modified: qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/management/JMXManagedObjectRegistry.java
URL: http://svn.apache.org/viewvc/qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/management/JMXManagedObjectRegistry.java?rev=821755&r1=821754&r2=821755&view=diff
==============================================================================
--- qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/management/JMXManagedObjectRegistry.java (original)
+++ qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/management/JMXManagedObjectRegistry.java Mon Oct 5 11:11:05 2009
@@ -27,6 +27,8 @@
import org.apache.qpid.server.registry.IApplicationRegistry;
import org.apache.qpid.server.security.auth.database.PrincipalDatabase;
import org.apache.qpid.server.security.auth.rmi.RMIPasswordAuthenticator;
+import org.apache.qpid.server.logging.actors.CurrentActor;
+import org.apache.qpid.server.logging.messages.ManagementConsoleMessages;
import javax.management.JMException;
import javax.management.MBeanServer;
@@ -91,6 +93,9 @@
public void start() throws IOException, ConfigurationException
{
+
+ CurrentActor.get().message(ManagementConsoleMessages.MNG_1001());
+
//check if system properties are set to use the JVM's out-of-the-box JMXAgent
if (areOutOfTheBoxJMXOptionsSet())
{
@@ -160,6 +165,8 @@
_log.info("JMX ConnectorServer using SSL keystore file " + ksf.getAbsolutePath());
_startupLog.info("JMX ConnectorServer using SSL keystore file " + ksf.getAbsolutePath());
+
+ CurrentActor.get().message(ManagementConsoleMessages.MNG_1006(ksf.getAbsolutePath()));
}
//check the key store password is set
@@ -186,6 +193,10 @@
(port +PORT_EXPORT_OFFSET) + ") with SSL");
_startupLog.warn("Starting JMX ConnectorServer on port '"+ port + "' (+" +
(port +PORT_EXPORT_OFFSET) + ") with SSL");
+
+ CurrentActor.get().message(ManagementConsoleMessages.MNG_1002("SSL RMI Registry", port));
+ CurrentActor.get().message(ManagementConsoleMessages.MNG_1002("SSL RMI ConnectorServer", port + PORT_EXPORT_OFFSET));
+
}
else
{
@@ -195,6 +206,8 @@
_log.warn("Starting JMX ConnectorServer on port '" + port + "' (+" + (port +PORT_EXPORT_OFFSET) + ")");
_startupLog.warn("Starting JMX ConnectorServer on port '" + port + "' (+" + (port +PORT_EXPORT_OFFSET) + ")");
+ CurrentActor.get().message(ManagementConsoleMessages.MNG_1002("RMI Registry", port));
+ CurrentActor.get().message(ManagementConsoleMessages.MNG_1002("RMI ConnectorServer", port + PORT_EXPORT_OFFSET));
}
//add a JMXAuthenticator implementation the env map to authenticate the RMI based JMX connector server
@@ -233,7 +246,7 @@
try
{
//manually bind the connector server to the registry at key 'jmxrmi', like the out-of-the-box agent
- _rmiRegistry.bind("jmxrmi", rmiConnectorServerStub);
+ _rmiRegistry.bind("jmxrmi", rmiConnectorServerStub);
}
catch (AlreadyBoundException abe)
{
@@ -263,6 +276,8 @@
MBeanServerForwarder mbsf = MBeanInvocationHandlerImpl.newProxyInstance();
cs.setMBeanServerForwarder(mbsf);
cs.start();
+
+ CurrentActor.get().message(ManagementConsoleMessages.MNG_1004());
}
/*
@@ -366,6 +381,8 @@
_log.error("Exception unregistering MBean '"+ name +"': " + e.getMessage());
}
}
+
+ CurrentActor.get().message(ManagementConsoleMessages.MNG_1005());
}
}
Propchange: qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/queue/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Mon Oct 5 11:11:05 2009
@@ -1,3 +1,3 @@
/qpid/branches/0.5-release/qpid/java/broker/src/main/java/org/apache/qpid/server/queue:757257
/qpid/branches/jmx_mc_gsoc09/qpid/java/broker/src/main/java/org/apache/qpid/server/queue:787599
-/qpid/trunk/qpid/java/broker/src/main/java/org/apache/qpid/server/queue:753219-753220,753253,757270,758730,759097,760919,761721,762365,762992,763959,764026,764109,764140,764790,796196-800440
+/qpid/trunk/qpid/java/broker/src/main/java/org/apache/qpid/server/queue:753219-753220,753253,757270,758730,759097,760919,761721,762365,762992,763959,764026,764109,764140,764790,796196-802129
Modified: qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/queue/ExchangeBinding.java
URL: http://svn.apache.org/viewvc/qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/queue/ExchangeBinding.java?rev=821755&r1=821754&r2=821755&view=diff
==============================================================================
--- qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/queue/ExchangeBinding.java (original)
+++ qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/queue/ExchangeBinding.java Mon Oct 5 11:11:05 2009
@@ -21,6 +21,10 @@
package org.apache.qpid.server.queue;
import org.apache.qpid.server.exchange.Exchange;
+import org.apache.qpid.server.logging.actors.CurrentActor;
+import org.apache.qpid.server.logging.messages.BindingMessages;
+import org.apache.qpid.server.logging.subjects.BindingLogSubject;
+import org.apache.qpid.server.logging.LogSubject;
import org.apache.qpid.framing.AMQShortString;
import org.apache.qpid.framing.FieldTable;
import org.apache.qpid.AMQException;
@@ -31,23 +35,26 @@
private final AMQShortString _routingKey;
private final FieldTable _arguments;
- private static final FieldTable EMPTY_ARGUMENTS = new FieldTable();
+ private static final FieldTable EMPTY_ARGUMENTS = new FieldTable();
+ private LogSubject _logSubject;
- ExchangeBinding(AMQShortString routingKey, Exchange exchange)
- {
- this(routingKey, exchange, EMPTY_ARGUMENTS);
- }
-
- ExchangeBinding(AMQShortString routingKey, Exchange exchange, FieldTable arguments)
+ ExchangeBinding(AMQShortString routingKey, Exchange exchange, AMQQueue queue, FieldTable arguments)
{
_routingKey = routingKey == null ? AMQShortString.EMPTY_STRING : routingKey;
_exchange = exchange;
_arguments = arguments == null ? EMPTY_ARGUMENTS : arguments;
+ _logSubject = new BindingLogSubject(routingKey,exchange,queue);
+
+ CurrentActor.get().message(_logSubject, BindingMessages.BND_1001(_arguments.toString(), arguments != null));
}
+
+
void unbind(AMQQueue queue) throws AMQException
{
_exchange.deregisterQueue(_routingKey, queue, _arguments);
+
+ CurrentActor.get().message(_logSubject, BindingMessages.BND_1002());
}
public Exchange getExchange()
Modified: qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/queue/ExchangeBindings.java
URL: http://svn.apache.org/viewvc/qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/queue/ExchangeBindings.java?rev=821755&r1=821754&r2=821755&view=diff
==============================================================================
--- qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/queue/ExchangeBindings.java (original)
+++ qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/queue/ExchangeBindings.java Mon Oct 5 11:11:05 2009
@@ -52,13 +52,13 @@
*/
void addBinding(AMQShortString routingKey, FieldTable arguments, Exchange exchange)
{
- _bindings.add(new ExchangeBinding(routingKey, exchange, arguments));
+ _bindings.add(new ExchangeBinding(routingKey, exchange, _queue, arguments));
}
public boolean remove(AMQShortString routingKey, FieldTable arguments, Exchange exchange)
{
- return _bindings.remove(new ExchangeBinding(routingKey, exchange, arguments));
+ return _bindings.remove(new ExchangeBinding(routingKey, exchange, _queue, arguments));
}
Modified: qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/queue/SimpleAMQQueue.java
URL: http://svn.apache.org/viewvc/qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/queue/SimpleAMQQueue.java?rev=821755&r1=821754&r2=821755&view=diff
==============================================================================
--- qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/queue/SimpleAMQQueue.java (original)
+++ qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/queue/SimpleAMQQueue.java Mon Oct 5 11:11:05 2009
@@ -24,6 +24,10 @@
import org.apache.qpid.server.virtualhost.VirtualHost;
import org.apache.qpid.server.message.ServerMessage;
import org.apache.qpid.server.PrincipalHolder;
+import org.apache.qpid.server.logging.actors.CurrentActor;
+import org.apache.qpid.server.logging.subjects.QueueLogSubject;
+import org.apache.qpid.server.logging.LogSubject;
+import org.apache.qpid.server.logging.messages.QueueMessages;
/*
*
@@ -140,6 +144,7 @@
private AtomicReference _asynchronousRunner = new AtomicReference(null);
private AtomicInteger _deliveredMessages = new AtomicInteger();
private AtomicBoolean _stopped = new AtomicBoolean(false);
+ private LogSubject _logSubject;
protected SimpleAMQQueue(AMQShortString name, boolean durable, AMQShortString owner, boolean autoDelete, VirtualHost virtualHost)
throws AMQException
@@ -175,6 +180,27 @@
_asyncDelivery = ReferenceCountingExecutorService.getInstance().acquireExecutorService();
+ _logSubject = new QueueLogSubject(this);
+
+ // Log the correct creation message
+
+ // Extract the number of priorities for this Queue.
+ // Leave it as 0 if we are a SimpleQueueEntryList
+ int priorities = 0;
+ if (entryListFactory instanceof PriorityQueueList.Factory)
+ {
+ priorities = ((PriorityQueueList)_entries).getPriorities();
+ }
+
+ // Log the creation of this Queue.
+ // The priorities display is toggled on if we set priorities > 0
+ CurrentActor.get().message(_logSubject,
+ QueueMessages.QUE_1001(String.valueOf(_owner),
+ priorities,
+ autoDelete,
+ durable, !durable,
+ priorities > 0));
+
try
{
_managedObject = new AMQQueueMBean(this);
@@ -282,15 +308,6 @@
}
_bindings.addBinding(routingKey, arguments, exchange);
-// ExchangeBinding binding = new ExchangeBinding(routingKey, exchange, arguments);
-
- //fixme MR logging in progress
-// _bindings.addBinding(binding);
-//
-// if (_logger.isMessageEnabled(binding))
-// {
-// _logger.message(binding, "QM-1001 : Created Binding");
-// }
}
public void unBind(Exchange exchange, AMQShortString routingKey, FieldTable arguments) throws AMQException
@@ -342,7 +359,7 @@
if (!isDeleted())
{
- subscription.setQueue(this);
+ subscription.setQueue(this, exclusive);
_subscriptionList.add(subscription);
if (isDeleted())
{
@@ -497,7 +514,7 @@
}
_managedObject.checkForNotification(entry.getMessage());
-
+
return entry;
}
@@ -881,11 +898,11 @@
return entryList;
}
-
+
/**
* Returns a list of QueEntries from a given range of queue positions, eg messages 5 to 10 on the queue.
- *
- * The 'queue position' index starts from 1. Using 0 in 'from' will be ignored and continue from 1.
+ *
+ * The 'queue position' index starts from 1. Using 0 in 'from' will be ignored and continue from 1.
* Using 0 in the 'to' field will return an empty list regardless of the 'from' value.
* @param fromPosition
* @param toPosition
@@ -894,7 +911,7 @@
public List<QueueEntry> getMessagesRangeOnTheQueue(final long fromPosition, final long toPosition)
{
List<QueueEntry> queueEntries = new ArrayList<QueueEntry>();
-
+
QueueEntryIterator it = _entries.iterator();
long index = 1;
@@ -902,20 +919,20 @@
{
it.advance();
}
-
+
if(index < fromPosition)
{
//The queue does not contain enough entries to reach our range.
//return the empty list.
return queueEntries;
}
-
+
for ( ; index <= toPosition && !it.atTail(); index++)
{
it.advance();
queueEntries.add(it.getNode());
}
-
+
return queueEntries;
}
@@ -1201,6 +1218,10 @@
_deleteTaskList.clear();
stop();
+
+ //Log Queue Deletion
+ CurrentActor.get().message(_logSubject, QueueMessages.QUE_1002());
+
}
return getMessageCount();
@@ -1271,6 +1292,7 @@
boolean complete = false;
try
{
+ CurrentActor.set(_sub.getLogActor());
complete = flushSubscription(_sub, new Long(MAX_ASYNC_DELIVERIES));
}
@@ -1278,11 +1300,16 @@
{
_logger.error(e);
}
+ finally
+ {
+ CurrentActor.remove();
+ }
if (!complete && !_sub.isSuspended())
{
_asyncDelivery.execute(this);
}
+
}
public boolean isRead()
@@ -1307,7 +1334,7 @@
while (!sub.isSuspended() && !atTail && iterations != 0)
{
- try
+ try
{
sub.getSendLock();
atTail = attemptDelivery(sub);
@@ -1538,8 +1565,8 @@
if (!node.isDeleted() && node.expired() && node.acquire())
{
node.discard(storeContext);
- }
- else
+ }
+ else
{
_managedObject.checkForNotification(node.getMessage());
}
Modified: qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/registry/ApplicationRegistry.java
URL: http://svn.apache.org/viewvc/qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/registry/ApplicationRegistry.java?rev=821755&r1=821754&r2=821755&view=diff
==============================================================================
--- qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/registry/ApplicationRegistry.java (original)
+++ qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/registry/ApplicationRegistry.java Mon Oct 5 11:11:05 2009
@@ -26,7 +26,6 @@
import org.apache.commons.configuration.ConfigurationException;
import org.apache.log4j.Logger;
-import org.apache.mina.common.IoAcceptor;
import org.apache.qpid.server.configuration.ServerConfiguration;
import org.apache.qpid.server.management.ManagedObjectRegistry;
import org.apache.qpid.server.plugins.PluginManager;
@@ -36,6 +35,9 @@
import org.apache.qpid.server.virtualhost.VirtualHost;
import org.apache.qpid.server.virtualhost.VirtualHostRegistry;
import org.apache.qpid.server.logging.RootMessageLogger;
+import org.apache.qpid.server.logging.messages.BrokerMessages;
+import org.apache.qpid.server.logging.actors.CurrentActor;
+import org.apache.qpid.server.transport.QpidAcceptor;
/**
* An abstract application registry that provides access to configuration information and handles the
@@ -57,7 +59,7 @@
public static final String DEFAULT_APPLICATION_REGISTRY = "org.apache.qpid.server.util.NullApplicationRegistry";
public static String _APPLICATION_REGISTRY = DEFAULT_APPLICATION_REGISTRY;
- protected final Map<InetSocketAddress, IoAcceptor> _acceptors = new HashMap<InetSocketAddress, IoAcceptor>();
+ protected final Map<InetSocketAddress, QpidAcceptor> _acceptors = new HashMap<InetSocketAddress, QpidAcceptor>();
protected ManagedObjectRegistry _managedObjectRegistry;
@@ -114,12 +116,29 @@
}
}
+ public static boolean isConfigured()
+ {
+ return isConfigured(DEFAULT_INSTANCE);
+ }
+
+ public static boolean isConfigured(int instanceID)
+ {
+ return _instanceMap.containsKey(instanceID);
+ }
+
+ /**
+ * Method to cleanly shutdown the default registry running in this JVM
+ */
+ public static void remove()
+ {
+ remove(DEFAULT_INSTANCE);
+ }
+
/**
* Method to cleanly shutdown specified registry running in this JVM
*
* @param instanceID the instance to shutdown
*/
-
public static void remove(int instanceID)
{
try
@@ -228,6 +247,8 @@
}
// _pluginManager.close();
+
+ CurrentActor.get().message(BrokerMessages.BRK_1005());
}
private void unbind()
@@ -236,8 +257,9 @@
{
for (InetSocketAddress bindAddress : _acceptors.keySet())
{
- IoAcceptor acceptor = _acceptors.get(bindAddress);
- acceptor.unbind(bindAddress);
+ QpidAcceptor acceptor = _acceptors.get(bindAddress);
+ acceptor.getIoAcceptor().unbind(bindAddress);
+ CurrentActor.get().message(BrokerMessages.BRK_1003(acceptor.toString(), bindAddress.getPort()));
}
}
}
@@ -247,7 +269,7 @@
return _configuration;
}
- public void addAcceptor(InetSocketAddress bindAddress, IoAcceptor acceptor)
+ public void addAcceptor(InetSocketAddress bindAddress, QpidAcceptor acceptor)
{
synchronized (_acceptors)
{
Modified: qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/registry/ConfigurationFileApplicationRegistry.java
URL: http://svn.apache.org/viewvc/qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/registry/ConfigurationFileApplicationRegistry.java?rev=821755&r1=821754&r2=821755&view=diff
==============================================================================
--- qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/registry/ConfigurationFileApplicationRegistry.java (original)
+++ qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/registry/ConfigurationFileApplicationRegistry.java Mon Oct 5 11:11:05 2009
@@ -20,11 +20,15 @@
*/
package org.apache.qpid.server.registry;
-import java.io.File;
-
import org.apache.commons.configuration.ConfigurationException;
import org.apache.qpid.AMQException;
+import org.apache.qpid.common.QpidProperties;
import org.apache.qpid.server.configuration.ServerConfiguration;
+import org.apache.qpid.server.logging.RootMessageLoggerImpl;
+import org.apache.qpid.server.logging.messages.BrokerMessages;
+import org.apache.qpid.server.logging.actors.CurrentActor;
+import org.apache.qpid.server.logging.actors.BrokerActor;
+import org.apache.qpid.server.logging.rawloggers.Log4jMessageLogger;
import org.apache.qpid.server.management.JMXManagedObjectRegistry;
import org.apache.qpid.server.management.NoopManagedObjectRegistry;
import org.apache.qpid.server.plugins.PluginManager;
@@ -33,8 +37,8 @@
import org.apache.qpid.server.security.auth.manager.PrincipalDatabaseAuthenticationManager;
import org.apache.qpid.server.virtualhost.VirtualHost;
import org.apache.qpid.server.virtualhost.VirtualHostRegistry;
-import org.apache.qpid.server.logging.RootMessageLoggerImpl;
-import org.apache.qpid.server.logging.rawloggers.Log4jMessageLogger;
+
+import java.io.File;
public class ConfigurationFileApplicationRegistry extends ApplicationRegistry
{
@@ -48,6 +52,10 @@
{
_rootMessageLogger = new RootMessageLoggerImpl(_configuration,
new Log4jMessageLogger());
+ // Set the Actor for current log messages
+ CurrentActor.set(new BrokerActor(_rootMessageLogger));
+
+ CurrentActor.get().message(BrokerMessages.BRK_1001(QpidProperties.getReleaseVersion(),QpidProperties.getBuildVersion()));
initialiseManagedObjectRegistry();
@@ -67,6 +75,23 @@
initialiseVirtualHosts();
+ // Startup complete pop the current actor
+ CurrentActor.remove();
+ }
+
+ @Override
+ public void close() throws Exception
+ {
+ //Set the Actor for Broker Shutdown
+ CurrentActor.set(new BrokerActor(_rootMessageLogger));
+ try
+ {
+ super.close();
+ }
+ finally
+ {
+ CurrentActor.remove();
+ }
}
private void initialiseVirtualHosts() throws Exception
Modified: qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/registry/IApplicationRegistry.java
URL: http://svn.apache.org/viewvc/qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/registry/IApplicationRegistry.java?rev=821755&r1=821754&r2=821755&view=diff
==============================================================================
--- qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/registry/IApplicationRegistry.java (original)
+++ qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/registry/IApplicationRegistry.java Mon Oct 5 11:11:05 2009
@@ -34,6 +34,7 @@
import org.apache.qpid.server.security.access.ACLPlugin;
import org.apache.qpid.server.virtualhost.VirtualHostRegistry;
import org.apache.qpid.server.logging.RootMessageLogger;
+import org.apache.qpid.server.transport.QpidAcceptor;
import org.apache.mina.common.IoAcceptor;
public interface IApplicationRegistry
@@ -77,6 +78,6 @@
* @param bindAddress The address that the acceptor has been bound with
* @param acceptor The acceptor in use
*/
- void addAcceptor(InetSocketAddress bindAddress, IoAcceptor acceptor);
+ void addAcceptor(InetSocketAddress bindAddress, QpidAcceptor acceptor);
}
Modified: qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/store/DerbyMessageStore.java
URL: http://svn.apache.org/viewvc/qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/store/DerbyMessageStore.java?rev=821755&r1=821754&r2=821755&view=diff
==============================================================================
--- qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/store/DerbyMessageStore.java (original)
+++ qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/store/DerbyMessageStore.java Mon Oct 5 11:11:05 2009
@@ -20,49 +20,51 @@
*/
package org.apache.qpid.server.store;
-import org.apache.qpid.server.virtualhost.VirtualHost;
+import org.apache.log4j.Logger;
+import org.apache.mina.common.ByteBuffer;
+import org.apache.qpid.AMQException;
+import org.apache.qpid.framing.AMQShortString;
+import org.apache.qpid.framing.ContentHeaderBody;
+import org.apache.qpid.framing.FieldTable;
+import org.apache.qpid.framing.abstraction.ContentChunk;
+import org.apache.qpid.framing.abstraction.MessagePublishInfo;
import org.apache.qpid.server.configuration.VirtualHostConfiguration;
import org.apache.qpid.server.exchange.Exchange;
+import org.apache.qpid.server.logging.actors.BrokerActor;
+import org.apache.qpid.server.logging.actors.CurrentActor;
+import org.apache.qpid.server.logging.messages.MessageStoreMessages;
+import org.apache.qpid.server.logging.subjects.MessageStoreLogSubject;
+import org.apache.qpid.server.queue.AMQMessage;
import org.apache.qpid.server.queue.AMQQueue;
import org.apache.qpid.server.queue.AMQQueueFactory;
+import org.apache.qpid.server.queue.MessageHandleFactory;
import org.apache.qpid.server.queue.MessageMetaData;
import org.apache.qpid.server.queue.QueueRegistry;
-
-import org.apache.qpid.server.queue.AMQMessage;
-import org.apache.qpid.server.queue.MessageHandleFactory;
-import org.apache.qpid.server.txn.TransactionalContext;
import org.apache.qpid.server.txn.NonTransactionalContext;
-import org.apache.qpid.AMQException;
-import org.apache.qpid.framing.AMQShortString;
-import org.apache.qpid.framing.FieldTable;
-import org.apache.qpid.framing.ContentHeaderBody;
-import org.apache.qpid.framing.abstraction.ContentChunk;
-import org.apache.qpid.framing.abstraction.MessagePublishInfo;
-import org.apache.commons.configuration.Configuration;
-import org.apache.log4j.Logger;
-import org.apache.mina.common.ByteBuffer;
+import org.apache.qpid.server.txn.TransactionalContext;
+import org.apache.qpid.server.virtualhost.VirtualHost;
-import java.io.File;
import java.io.ByteArrayInputStream;
-import java.sql.DriverManager;
-import java.sql.Driver;
+import java.io.File;
+import java.sql.Blob;
import java.sql.Connection;
-import java.sql.SQLException;
-import java.sql.Statement;
+import java.sql.Driver;
+import java.sql.DriverManager;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
-import java.sql.Blob;
+import java.sql.SQLException;
+import java.sql.Statement;
import java.sql.Types;
-import java.util.concurrent.atomic.AtomicLong;
-import java.util.concurrent.atomic.AtomicBoolean;
-import java.util.List;
import java.util.ArrayList;
-import java.util.Map;
import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
import java.util.TreeMap;
+import java.util.concurrent.atomic.AtomicBoolean;
+import java.util.concurrent.atomic.AtomicLong;
-public class DerbyMessageStore implements MessageStore
+public class DerbyMessageStore extends AbstractMessageStore
{
private static final Logger _logger = Logger.getLogger(DerbyMessageStore.class);
@@ -93,6 +95,7 @@
private String _connectionURL;
+ Map<AMQShortString, Integer> _queueRecoveries = new TreeMap<AMQShortString, Integer>();
private static final String CREATE_DB_VERSION_TABLE = "CREATE TABLE "+DB_VERSION_TABLE_NAME+" ( version int not null )";
@@ -145,6 +148,8 @@
public void configure(VirtualHost virtualHost, String base, VirtualHostConfiguration config) throws Exception
{
+ super.configure(virtualHost,base,config);
+
stateTransition(State.INITIAL, State.CONFIGURING);
initialiseDriver();
@@ -167,12 +172,15 @@
}
}
+ CurrentActor.get().message(_logSubject, MessageStoreMessages.MST_1002(environmentPath.getAbsolutePath()));
+
createOrOpenDatabase(databasePath);
// this recovers durable queues and persistent messages
recover();
+
stateTransition(State.RECOVERING, State.STARTED);
}
@@ -187,6 +195,7 @@
private void createOrOpenDatabase(final String environmentPath) throws SQLException
{
+ //fixme this the _vhost name should not be added here.
_connectionURL = "jdbc:derby:" + environmentPath + "/" + _virtualHost.getName() + ";create=true";
Connection conn = newConnection();
@@ -309,7 +318,8 @@
{
stateTransition(State.CONFIGURING, State.RECOVERING);
- _logger.info("Recovering persistent state...");
+ CurrentActor.get().message(_logSubject,MessageStoreMessages.MST_1004(null, false));
+
StoreContext context = new StoreContext();
try
@@ -324,9 +334,10 @@
beginTran(context);
deliverMessages(context, queues);
- _logger.info("Persistent state recovered successfully");
commitTran(context);
+ //Recovery Complete
+ CurrentActor.get().message(_logSubject, MessageStoreMessages.MST_1006(null, false));
}
finally
{
@@ -335,6 +346,7 @@
abortTran(context);
}
}
+
}
catch (SQLException e)
{
@@ -342,6 +354,7 @@
throw new AMQException("Error recovering persistent state: " + e, e);
}
+
}
private Map<AMQShortString, AMQQueue> loadQueues() throws SQLException, AMQException
@@ -368,6 +381,11 @@
}
queueMap.put(queueNameShortString,q);
+
+ CurrentActor.get().message(_logSubject,MessageStoreMessages.MST_1004(String.valueOf(q.getName()), true));
+
+ //Record that we have a queue for recovery
+ _queueRecoveries.put(new AMQShortString(queueName), 0);
}
return queueMap;
@@ -486,6 +504,8 @@
public void close() throws Exception
{
_closed.getAndSet(true);
+
+ super.close();
}
public void removeMessage(StoreContext storeContext, Long messageId) throws AMQException
@@ -1362,7 +1382,6 @@
_queue.enqueue(_message);
StoreContext.clearCurrentContext();
-
}
}
@@ -1374,13 +1393,11 @@
Map<Long, AMQMessage> msgMap = new HashMap<Long,AMQMessage>();
List<ProcessAction> actions = new ArrayList<ProcessAction>();
- Map<AMQShortString, Integer> queueRecoveries = new TreeMap<AMQShortString, Integer>();
final boolean inLocaltran = inTran(context);
Connection conn = null;
try
{
-
if(inLocaltran)
{
conn = getConnection(context);
@@ -1390,7 +1407,6 @@
conn = newConnection();
}
-
MessageHandleFactory messageHandleFactory = new MessageHandleFactory();
long maxId = 1;
@@ -1399,15 +1415,10 @@
Statement stmt = conn.createStatement();
ResultSet rs = stmt.executeQuery(SELECT_FROM_QUEUE_ENTRY);
-
while (rs.next())
{
-
-
-
AMQShortString queueName = new AMQShortString(rs.getString(1));
-
AMQQueue queue = queues.get(queueName);
if (queue == null)
{
@@ -1415,6 +1426,9 @@
_virtualHost.getQueueRegistry().registerQueue(queue);
queues.put(queueName, queue);
+
+ //Log Recovery Start
+ CurrentActor.get().message(_logSubject, MessageStoreMessages.MST_1004(String.valueOf(queue.getName()), true));
}
long messageId = rs.getLong(2);
@@ -1436,20 +1450,15 @@
_logger.debug("On recovery, delivering " + message.getMessageId() + " to " + queue.getName());
}
- if (_logger.isInfoEnabled())
+ Integer count = _queueRecoveries.get(queueName);
+ if (count == null)
{
- Integer count = queueRecoveries.get(queueName);
- if (count == null)
- {
- count = 0;
- }
-
- queueRecoveries.put(queueName, ++count);
-
+ count = 0;
}
- actions.add(new ProcessAction(queue, context, message));
+ _queueRecoveries.put(queueName, ++count);
+ actions.add(new ProcessAction(queue, context, message));
}
for(ProcessAction action : actions)
@@ -1474,8 +1483,19 @@
if (_logger.isInfoEnabled())
{
- _logger.info("Recovered message counts: " + queueRecoveries);
+ _logger.info("Recovered message counts: " + _queueRecoveries);
}
+
+ for(Map.Entry<AMQShortString,Integer> entry : _queueRecoveries.entrySet())
+ {
+ CurrentActor.get().message(_logSubject, MessageStoreMessages.MST_1005(entry.getValue(), String.valueOf(entry.getKey())));
+
+ CurrentActor.get().message(_logSubject, MessageStoreMessages.MST_1006(String.valueOf(entry.getKey()), true));
+ }
+
+ // Free the memory
+ _queueRecoveries = null;
+
}
private Connection getConnection(final StoreContext context)
Modified: qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/store/MemoryMessageStore.java
URL: http://svn.apache.org/viewvc/qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/store/MemoryMessageStore.java?rev=821755&r1=821754&r2=821755&view=diff
==============================================================================
--- qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/store/MemoryMessageStore.java (original)
+++ qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/store/MemoryMessageStore.java Mon Oct 5 11:11:05 2009
@@ -31,6 +31,10 @@
import org.apache.qpid.server.exchange.Exchange;
import org.apache.qpid.server.queue.AMQQueue;
import org.apache.qpid.server.virtualhost.VirtualHost;
+import org.apache.qpid.server.logging.actors.CurrentActor;
+import org.apache.qpid.server.logging.LogSubject;
+import org.apache.qpid.server.logging.messages.MessageStoreMessages;
+import org.apache.qpid.server.logging.subjects.MessageStoreLogSubject;
import java.util.ArrayList;
import java.util.Collections;
@@ -41,7 +45,7 @@
import java.util.concurrent.atomic.AtomicLong;
/** A simple message store that stores the messages in a threadsafe structure in memory. */
-public class MemoryMessageStore implements MessageStore
+public class MemoryMessageStore extends AbstractMessageStore
{
private static final Logger _log = Logger.getLogger(MemoryMessageStore.class);
@@ -55,27 +59,18 @@
private final AtomicLong _messageId = new AtomicLong(1);
private AtomicBoolean _closed = new AtomicBoolean(false);
+ private LogSubject _logSubject;
- public void configure()
+ public void configure(VirtualHost virtualHost, String base, VirtualHostConfiguration config) throws Exception
{
- _log.info("Using capacity " + DEFAULT_HASHTABLE_CAPACITY + " for hash tables");
- _metaDataMap = new ConcurrentHashMap<Long, MessageMetaData>(DEFAULT_HASHTABLE_CAPACITY);
- _contentBodyMap = new ConcurrentHashMap<Long, List<ContentChunk>>(DEFAULT_HASHTABLE_CAPACITY);
- }
+ super.configure(virtualHost,base,config);
- public void configure(String base, VirtualHostConfiguration config)
- {
int hashtableCapacity = config.getStoreConfiguration().getInt(base + "." + HASHTABLE_CAPACITY_CONFIG, DEFAULT_HASHTABLE_CAPACITY);
_log.info("Using capacity " + hashtableCapacity + " for hash tables");
_metaDataMap = new ConcurrentHashMap<Long, MessageMetaData>(hashtableCapacity);
_contentBodyMap = new ConcurrentHashMap<Long, List<ContentChunk>>(hashtableCapacity);
}
- public void configure(VirtualHost virtualHost, String base, VirtualHostConfiguration config) throws Exception
- {
- configure(base, config);
- }
-
public void close() throws Exception
{
_closed.getAndSet(true);
@@ -89,6 +84,8 @@
_contentBodyMap.clear();
_contentBodyMap = null;
}
+
+ super.close();
}
public void removeMessage(StoreContext context, Long messageId) throws AMQException
Modified: qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/subscription/Subscription.java
URL: http://svn.apache.org/viewvc/qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/subscription/Subscription.java?rev=821755&r1=821754&r2=821755&view=diff
==============================================================================
--- qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/subscription/Subscription.java (original)
+++ qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/subscription/Subscription.java Mon Oct 5 11:11:05 2009
@@ -23,12 +23,13 @@
import org.apache.qpid.AMQException;
import org.apache.qpid.framing.AMQShortString;
import org.apache.qpid.server.AMQChannel;
+import org.apache.qpid.server.logging.LogActor;
import org.apache.qpid.server.queue.AMQQueue;
import org.apache.qpid.server.queue.QueueEntry;
public interface Subscription
{
-
+ LogActor getLogActor();
public static enum State
{
@@ -46,7 +47,7 @@
QueueEntry.SubscriptionAcquiredState getOwningState();
- void setQueue(AMQQueue queue);
+ void setQueue(AMQQueue queue, boolean exclusive);
AMQShortString getConsumerTag();
Modified: qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/subscription/SubscriptionImpl.java
URL: http://svn.apache.org/viewvc/qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/subscription/SubscriptionImpl.java?rev=821755&r1=821754&r2=821755&view=diff
==============================================================================
--- qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/subscription/SubscriptionImpl.java (original)
+++ qpid/branches/java-broker-0-10/qpid/java/broker/src/main/java/org/apache/qpid/server/subscription/SubscriptionImpl.java Mon Oct 5 11:11:05 2009
@@ -34,6 +34,12 @@
import org.apache.qpid.framing.FieldTable;
import org.apache.qpid.server.AMQChannel;
import org.apache.qpid.server.output.ProtocolOutputConverter;
+import org.apache.qpid.server.logging.actors.CurrentActor;
+import org.apache.qpid.server.logging.actors.SubscriptionActor;
+import org.apache.qpid.server.logging.messages.SubscriptionMessages;
+import org.apache.qpid.server.logging.subjects.SubscriptionLogSubject;
+import org.apache.qpid.server.logging.LogSubject;
+import org.apache.qpid.server.logging.LogActor;
import org.apache.qpid.server.queue.QueueEntry;
import org.apache.qpid.server.queue.AMQQueue;
import org.apache.qpid.server.queue.AMQMessage;
@@ -66,14 +72,15 @@
private final ClientDeliveryMethod _deliveryMethod;
private final RecordDeliveryMethod _recordMethod;
-
+
private QueueEntry.SubscriptionAcquiredState _owningState = new QueueEntry.SubscriptionAcquiredState(this);
private final Lock _stateChangeLock;
private static final AtomicLong idGenerator = new AtomicLong(0);
// Create a simple ID that increments for ever new Subscription
private final long _subscriptionID = idGenerator.getAndIncrement();
-
+ private LogSubject _logSubject;
+ private LogActor _logActor;
static final class BrowserSubscription extends SubscriptionImpl
{
@@ -281,7 +288,7 @@
-
+
public SubscriptionImpl(AMQChannel channel , AMQProtocolSession protocolSession,
AMQShortString consumerTag, FieldTable arguments,
boolean noLocal, FlowCreditManager creditManager,
@@ -330,13 +337,52 @@
- public synchronized void setQueue(AMQQueue queue)
+ public synchronized void setQueue(AMQQueue queue, boolean exclusive)
{
if(getQueue() != null)
{
throw new IllegalStateException("Attempt to set queue for subscription " + this + " to " + queue + "when already set to " + getQueue());
}
_queue = queue;
+
+ _logSubject = new SubscriptionLogSubject(this);
+ _logActor = new SubscriptionActor(CurrentActor.get().getRootMessageLogger(), this);
+
+ if (CurrentActor.get().getRootMessageLogger().
+ isMessageEnabled(CurrentActor.get(), _logSubject))
+ {
+ // Get the string value of the filters
+ String filterLogString = null;
+ if (_filters != null && _filters.hasFilters())
+ {
+ filterLogString = _filters.toString();
+ }
+
+ if (isAutoClose())
+ {
+ if (filterLogString == null)
+ {
+ filterLogString = "";
+ }
+ else
+ {
+ filterLogString += ",";
+ }
+ filterLogString += "AutoClose";
+ }
+
+ if (isBrowser())
+ {
+ // We do not need to check for null here as all Browsers are AutoClose
+ filterLogString +=",Browser";
+ }
+
+ CurrentActor.get().
+ message(_logSubject,
+ SubscriptionMessages.SUB_1001(filterLogString,
+ queue.isDurable() && exclusive,
+ filterLogString != null));
+ }
}
public String toString()
@@ -494,20 +540,8 @@
}
- if (closed)
- {
- if (_logger.isDebugEnabled())
- {
- _logger.debug("Called close() on a closed subscription");
- }
-
- return;
- }
-
- if (_logger.isInfoEnabled())
- {
- _logger.info("Closing subscription (" + debugIdentity() + "):" + this);
- }
+ //Log Subscription closed
+ CurrentActor.get().message(_logSubject, SubscriptionMessages.SUB_1002());
}
public boolean isClosed()
@@ -551,9 +585,14 @@
return _channel.getProtocolSession();
}
+ public LogActor getLogActor()
+ {
+ return _logActor;
+ }
+
public AMQQueue getQueue()
{
- return _queue;
+ return _queue;
}
public void onDequeue(final QueueEntry queueEntry)
@@ -570,7 +609,7 @@
public void creditStateChanged(boolean hasCredit)
{
-
+
if(hasCredit)
{
if(_state.compareAndSet(State.SUSPENDED, State.ACTIVE))
---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project: http://qpid.apache.org
Use/Interact: mailto:commits-subscribe@qpid.apache.org