activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gary Tully <gary.tu...@gmail.com>
Subject Re: Cryptic error time!
Date Wed, 25 Aug 2010 13:48:22 GMT
yea, it looks like it warrants an issue. Have a look at the java stomp
tests, that use a trivial java stomp client.

org.apache.activemq.transport.stomp.StompTest in activemq-core for
some inspiration for a junit test.

On 25 August 2010 14:29, James Green <james.mk.green@gmail.com> wrote:
> Hmm, I'm connecting to both hub and spoke using PHP with the PECL
> Stomp library (1.0.1).
>
> To the hub I'm sending to /topic/accounts with a header 'persistent' => 'true'.
>
> To the spoke I am subscribing to /topic/accounts with a client-id of
> 'sutton_accounts'. I use the same 'sutton_accounts' value for the
> 'activemq.subscriptionName' header.
>
> On the spoke my networkConnectors:
>        <networkConnectors>
>            <networkConnector uri="static://(ssl://the-hub:61617)"
>                name="hub"
>                duplex="true"
>                conduitSubscriptions="false"
>                dynamicOnly="false">
>                <excludedDestinations>
>                    <queue physicalName="software"/>
>                </excludedDestinations>
>                <staticallyIncludedDestinations>
>                    <topic physicalName="accounts"/>
>                </staticallyIncludedDestinations>
>            </networkConnector>
>        </networkConnectors>
>
> If this all looks good then I can open a Jira ticket - I've not done
> anything in junit before so forgive me if I'm not the most forthcoming
> on that one (can't be that different to phpunit, right?).
>
> Just don't want to pollute Jira with what might be configuration issues my end!
>
> James
>
> On 25 August 2010 14:12, Gary Tully <gary.tully@gmail.com> wrote:
>> What frames are being used to the create the stomp subscription.
>>
>> From the code, there is a subscription name present in the consumer
>> info so it is attempting to treat it as a durable topic subscription
>> when in fact it is a queue subscription.
>>
>> Can you post the relevant stomp frames, and possibly open a jira issue
>> to track this and collect the relevant information.
>> Ideally a test case that can reproduce would be great. This seems to
>> be a stomp/openwire mismatch or a series of stomp commands in the
>> wrong order or is there a composite destination?
>>
>> On 25 August 2010 13:55, James Green <james.mk.green@gmail.com> wrote:
>>> Both servers are 5.4.0 on Ubuntu.
>>>
>>> From the hub in full:
>>> [ .. ]
>>> java.lang.ClassCastException:
>>> org.apache.activemq.broker.region.QueueSubscription cannot be cast to
>>> org.apache.activemq.broker.region.DurableTopicSubscription
>>>        at org.apache.activemq.broker.jmx.DurableSubscriptionView.<init>(DurableSubscriptionView.java:46)
>>>        at org.apache.activemq.broker.jmx.ManagedRegionBroker.registerSubscription(ManagedRegionBroker.java:188)
>>>        at org.apache.activemq.broker.jmx.ManagedQueueRegion.createSubscription(ManagedQueueRegion.java:45)
>>>        at org.apache.activemq.broker.region.AbstractRegion.addConsumer(AbstractRegion.java:268)
>>>        at org.apache.activemq.broker.region.RegionBroker.addConsumer(RegionBroker.java:420)
>>>        at org.apache.activemq.broker.BrokerFilter.addConsumer(BrokerFilter.java:89)
>>>        at org.apache.activemq.broker.BrokerFilter.addConsumer(BrokerFilter.java:89)
>>>        at org.apache.activemq.advisory.AdvisoryBroker.addConsumer(AdvisoryBroker.java:91)
>>>        at org.apache.activemq.broker.BrokerFilter.addConsumer(BrokerFilter.java:89)
>>>        at org.apache.activemq.broker.BrokerFilter.addConsumer(BrokerFilter.java:89)
>>>        at org.apache.activemq.broker.MutableBrokerFilter.addConsumer(MutableBrokerFilter.java:95)
>>>        at org.apache.activemq.broker.TransportConnection.processAddConsumer(TransportConnection.java:548)
>>>        at org.apache.activemq.command.ConsumerInfo.visit(ConsumerInfo.java:349)
>>>        at org.apache.activemq.broker.TransportConnection.service(TransportConnection.java:309)
>>>        at org.apache.activemq.broker.TransportConnection$1.onCommand(TransportConnection.java:185)
>>>        at org.apache.activemq.transport.TransportFilter.onCommand(TransportFilter.java:69)
>>>        at org.apache.activemq.transport.stomp.StompTransportFilter.sendToActiveMQ(StompTransportFilter.java:81)
>>>        at org.apache.activemq.transport.stomp.ProtocolConverter.sendToActiveMQ(ProtocolConverter.java:140)
>>>        at org.apache.activemq.transport.stomp.ProtocolConverter.onStompSubscribe(ProtocolConverter.java:425)
>>>        at org.apache.activemq.transport.stomp.ProtocolConverter.onStompCommand(ProtocolConverter.java:188)
>>>        at org.apache.activemq.transport.stomp.StompTransportFilter.onCommand(StompTransportFilter.java:70)
>>>        at org.apache.activemq.transport.TransportSupport.doConsume(TransportSupport.java:83)
>>>        at org.apache.activemq.transport.tcp.TcpTransport.doRun(TcpTransport.java:219)
>>>        at org.apache.activemq.transport.tcp.TcpTransport.run(TcpTransport.java:201)
>>>        at java.lang.Thread.run(Thread.java:636)
>>>
>>> The spoke:
>>> [ ... ]
>>> java.lang.ClassCastException:
>>> org.apache.activemq.broker.region.QueueSubscription cannot be
>>> cast to org.apache.activemq.broker.region.DurableTopicSubscription
>>>        at org.apache.activemq.broker.jmx.DurableSubscriptionView.<init>(DurableSubscription
>>> View.java:46)
>>>        at org.apache.activemq.broker.jmx.ManagedRegionBroker.registerSubscription(ManagedRe
>>> gionBroker.java:188)
>>>        at org.apache.activemq.broker.jmx.ManagedQueueRegion.createSubscription(ManagedQueue
>>> Region.java:45)
>>>        at org.apache.activemq.broker.region.AbstractRegion.addConsumer(AbstractRegion.java:
>>> 268)
>>>        at org.apache.activemq.broker.region.RegionBroker.addConsumer(RegionBroker.java:420)
>>>        at org.apache.activemq.broker.BrokerFilter.addConsumer(BrokerFilter.java:89)
>>>        at org.apache.activemq.broker.BrokerFilter.addConsumer(BrokerFilter.java:89)
>>>        at org.apache.activemq.advisory.AdvisoryBroker.addConsumer(AdvisoryBroker.java:91)
>>>        at org.apache.activemq.broker.BrokerFilter.addConsumer(BrokerFilter.java:89)
>>>        at org.apache.activemq.broker.BrokerFilter.addConsumer(BrokerFilter.java:89)
>>>        at org.apache.activemq.broker.MutableBrokerFilter.addConsumer(MutableBrokerFilter.ja
>>> va:95)
>>>        at org.apache.activemq.broker.TransportConnection.processAddConsumer(TransportConnec
>>> tion.java:548)
>>>        at org.apache.activemq.command.ConsumerInfo.visit(ConsumerInfo.java:349)
>>>        at org.apache.activemq.broker.TransportConnection.service(TransportConnection.java:309)
>>>        at org.apache.activemq.broker.TransportConnection$1.onCommand(TransportConnection.java:185)
>>>        at org.apache.activemq.transport.ResponseCorrelator.onCommand(ResponseCorrelator.java:116)
>>>        at org.apache.activemq.transport.TransportFilter.onCommand(TransportFilter.java:69)
>>>        at org.apache.activemq.transport.vm.VMTransport.dispatch(VMTransport.java:121)
>>>        at org.apache.activemq.transport.vm.VMTransport.oneway(VMTransport.java:112)
>>>        at org.apache.activemq.transport.MutexTransport.oneway(MutexTransport.java:40)
>>>        at org.apache.activemq.transport.ResponseCorrelator.oneway(ResponseCorrelator.java:60)
>>>        at org.apache.activemq.network.DemandForwardingBridgeSupport.addSubscription(DemandForwardingBridgeSupport.java:652)
>>>        at org.apache.activemq.network.DemandForwardingBridgeSupport.addConsumerInfo(DemandForwardingBridgeSupport.java:1017)
>>>        at org.apache.activemq.network.DemandForwardingBridgeSupport.serviceRemoteConsumerAdvisory(DemandForwardingBridgeSupport.java:587)
>>>        at org.apache.activemq.network.DemandForwardingBridgeSupport.serviceRemoteCommand(DemandForwardingBridgeSupport.java:492)
>>>        at org.apache.activemq.network.DemandForwardingBridgeSupport$2.onCommand(DemandForwardingBridgeSupport.java:173)
>>>        at org.apache.activemq.transport.ResponseCorrelator.onCommand(ResponseCorrelator.java:116)
>>>        at org.apache.activemq.transport.TransportFilter.onCommand(TransportFilter.java:69)
>>>        at org.apache.activemq.transport.WireFormatNegotiator.onCommand(WireFormatNegotiator.java:113)
>>>        at org.apache.activemq.transport.InactivityMonitor.onCommand(InactivityMonitor.java:217)
>>>        at org.apache.activemq.transport.TransportSupport.doConsume(TransportSupport.java:83)
>>>        at org.apache.activemq.transport.tcp.SslTransport.doConsume(SslTransport.java:91)
>>>        at org.apache.activemq.transport.tcp.TcpTransport.doRun(TcpTransport.java:219)
>>>        at org.apache.activemq.transport.tcp.TcpTransport.run(TcpTransport.java:201)
>>>        at java.lang.Thread.run(Thread.java:636)
>>>
>>> On 25 August 2010 12:36, Gary Tully <gary.tully@gmail.com> wrote:
>>>> is there a stack trace? please post if there is.
>>>> what version of broker?
>>>>
>>>> On 25 August 2010 12:31, James Green <james.mk.green@gmail.com> wrote:
>>>>> On our hub I see the following:
>>>>>
>>>>> 2010-08-25 12:09:47,378 | ERROR | Failed to register subscription
>>>>> QueueSubscription: consumer=ID:billing-59361-1282733145999-6:14:-1:1,
>>>>> destinations=0, dispatched=0, delivered=0, pending=0 |
>>>>> org.apache.activemq.broker.jmx.ManagedRegionBroker | ActiveMQ
>>>>> Transport: tcp:///127.0.0.1:46902
>>>>> java.lang.ClassCastException:
>>>>> org.apache.activemq.broker.region.QueueSubscription cannot be cast to
>>>>> org.apache.activemq.broker.region.DurableTopicSubscription
>>>>>
>>>>> On one of our spokes I see:
>>>>>
>>>>> 2010-08-25 12:25:25,513 | ERROR | Failed to register subscription
>>>>> QueueSubscription: consume
>>>>> r=ID:sutton-47959-1282733262236-4:1:1:29, destinations=0,
>>>>> dispatched=0, delivered=0, pending
>>>>> =0 | org.apache.activemq.broker.jmx.ManagedRegionBroker | ActiveMQ
>>>>> Transport: ssl://the-hub/x.x.x.x.x:61617
>>>>> java.lang.ClassCastException:
>>>>> org.apache.activemq.broker.region.QueueSubscription cannot be
>>>>> cast to org.apache.activemq.broker.region.DurableTopicSubscription
>>>>>
>>>>> On the spoke I do have a durable subscriber. Not sure there's a
>>>>> problem with that though.
>>>>>
>>>>> Any ideas?
>>>>>
>>>>> James
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> http://blog.garytully.com
>>>>
>>>> Open Source Integration
>>>> http://fusesource.com
>>>>
>>>
>>
>>
>>
>> --
>> http://blog.garytully.com
>>
>> Open Source Integration
>> http://fusesource.com
>>
>



-- 
http://blog.garytully.com

Open Source Integration
http://fusesource.com

Mime
View raw message