[jira] Commented: (AMQ-930) Session 'consumers' hashtable susceptible to invalid operation exception
[ https://issues.apache.org/activemq/browse/AMQ-930?page=comments#action_36998 ] Bryan Schmidt commented on AMQ-930: --- Your solution looks good. Thanks! Session 'consumers' hashtable susceptible to invalid operation exception Key: AMQ-930 URL: https://issues.apache.org/activemq/browse/AMQ-930 Project: ActiveMQ Issue Type: Bug Components: NMS (C# client) Affects Versions: incubation Environment: Windows XP, NMS API running against a AMQ 4.0.2 provider Reporter: Bryan Schmidt In a multithreaded environment that reuses the Session object, the following exception is thrown: Invalid operation exception with the text: Collection was modified; enumeration operation may not execute. The exception is thrown when iterating through Session's consumers.Values collection. It appears that the lock is being ignored. Spinning up a new thread fixes the problem: --- Session.cs, DispatchAsyncMessages method --- public void DispatchAsyncMessages(object state) { // lets iterate through each consumer created by this session // ensuring that they have all pending messages dispatched lock (this) { // lets ensure that only 1 thread dispatches messages in a consumer at once foreach (MessageConsumer consumer in consumers.Values) { ThreadPool.QueueUserWorkItem(new WaitCallback(consumer.DispatchAsyncMessages)); } } } -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/activemq/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Commented: (AMQ-931) NMS test fails against trunk version of server
[ https://issues.apache.org/activemq/browse/AMQ-931?page=comments#action_36999 ] Bryan Schmidt commented on AMQ-931: --- Have a look at the WireFormatNegotiator.cd class. Specifically, public const int OPENWIRE_VERSION = 2; I had to change this value to 'OPENWIRE_VERSION = 1' in order to communicate with ActiveMQ 4.0.2. NMS test fails against trunk version of server -- Key: AMQ-931 URL: https://issues.apache.org/activemq/browse/AMQ-931 Project: ActiveMQ Issue Type: Bug Components: NMS (C# client) Environment: Gentoo Linux EM64T, Mono 1.1.17, AMQ SVN Reporter: Adam Wendt When running the test case against svn version of broker server the server generates this error: Exception in thread ActiveMQ Transport: tcp:///127.0.0.1:36117 java.lang.IllegalArgumentException: Invalid version: 0, could not load org.apache.activemq.openwire.v0.MarshallerFactory at org.apache.activemq.openwire.OpenWireFormat.setVersion(OpenWireFormat.java:328) at org.apache.activemq.openwire.OpenWireFormat.renegotiateWireFormat(OpenWireFormat.java:568) at org.apache.activemq.transport.WireFormatNegotiator.onCommand(WireFormatNegotiator.java:110) at org.apache.activemq.transport.InactivityMonitor.onCommand(InactivityMonitor.java:123) at org.apache.activemq.transport.TransportSupport.doConsume(TransportSupport.java:88) at org.apache.activemq.transport.tcp.TcpTransport.run(TcpTransport.java:129) at java.lang.Thread.run(Thread.java:595) The C# test runs fine against 4.0.1 or 4.0.2RC3 server -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/activemq/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Created: (AMQ-939) Build Issues
Build Issues Key: AMQ-939 URL: https://issues.apache.org/activemq/browse/AMQ-939 Project: ActiveMQ Issue Type: Bug Components: NMS (C# client) Affects Versions: incubation Reporter: Bryan Schmidt Priority: Minor The current activemq-dotnet.csproj (https://svn.apache.org/repos/asf/incubator/activemq/activemq-dotnet/trunk/activemq-dotnet.csproj) does not include WireFormatNegotiator.cs. Thus, building this project using Visual Studio will fail until the file is included. Please note that issue AMQ-931 also concerns the WireFormatNegotiator.cs file. Also, building activemq-dotnet using NANT will fail unless you copy the 'nunit.framework.dll' assembly to the folder containing 'nant.build' file. -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/activemq/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Created: (AMQ-930) Session 'consumers' hashtable susceptible to invalid operation exception
Session 'consumers' hashtable susceptible to invalid operation exception Key: AMQ-930 URL: https://issues.apache.org/activemq/browse/AMQ-930 Project: ActiveMQ Issue Type: Bug Components: NMS (C# client) Affects Versions: incubation Environment: Windows XP, NMS API running against a AMQ 4.0.2 provider Reporter: Bryan Schmidt In a multithreaded environment that reuses the Session object, the following exception is thrown: Invalid operation exception with the text: Collection was modified; enumeration operation may not execute. The exception is thrown when iterating through Session's consumers.Values collection. It appears that the lock is being ignored. Spinning up a new thread fixes the problem: --- Session.cs, DispatchAsyncMessages method --- public void DispatchAsyncMessages(object state) { // lets iterate through each consumer created by this session // ensuring that they have all pending messages dispatched lock (this) { // lets ensure that only 1 thread dispatches messages in a consumer at once foreach (MessageConsumer consumer in consumers.Values) { ThreadPool.QueueUserWorkItem(new WaitCallback(consumer.DispatchAsyncMessages)); } } } -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/activemq/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Created: (AMQ-883) NMS asynchronous consumption of queued messages
NMS asynchronous consumption of queued messages --- Key: AMQ-883 URL: https://issues.apache.org/activemq/browse/AMQ-883 Project: ActiveMQ Issue Type: Bug Components: NMS (C# client) Affects Versions: 4.0.2 Environment: Win XP, AMQ 4.0.2 standalone broker, Java message sender (JMS), C# (NMS) receiver Reporter: Bryan Schmidt 1. Several messages are sent to a queue 2. NMS client subscribes 3. Queued messages are not received by NMS client 4. Another message is sent to the queue (while the NMS client is subscribed) 5. NMS client receives all messages Same setup using Java publisher and subscriber behaves properly (queued messages are sent to the subscriber immediately). Editting the AsyncConsumeTest unit test can reproduce the problem and cause the test to fail: In the textMessageSRExample test, move the consumer logic below the producer logic. (I.e. have the message sent to a queue before the consumer subscribes). -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/activemq/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Created: (AMQ-680) JMX Registration Issue
JMX Registration Issue -- Key: AMQ-680 URL: https://issues.apache.org/activemq/browse/AMQ-680 Project: ActiveMQ Type: Bug Versions: 4.0 RC 2 Reporter: Bryan Schmidt After creating a new destination, rapid multithreaded MessageProducer.send's cause JMX registration conflict. Two or more MessageProducers attempt to register the newly created destination with JMX, hence raising the InstanceAlreadyExistsException. 16:05:57,609 ERROR [ManagedRegionBroker] Failed to register destination topic:// clientRecordQuery-1144357557593-41 javax.management.InstanceAlreadyExistsException: org.apache.activemq:BrokerName= localhost,Type=Topic,Destination=clientRecordQuery-1144357557593-41 already regi stered. -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/activemq/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira