activemq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From StefanL <stefan_...@yahoo.se>
Subject Empty message selector throws InvalidSelectorException
Date Tue, 04 Sep 2007 14:05:22 GMT

When I'm trying to apply the
https://issues.apache.org/activemq/browse/AMQNET-44 patch in nms I get an
exception in the broker since I send in an empty/blank selector.

According to jms doc I find this should be ok and null or empty shall be
treated as no selector.

The stack trace I get is:
Thread [ActiveMQ Transport: tcp:///127.0.0.1:2329] (Suspended (exception
InvalidSelectorException))	
	SelectorParser.parse(String) line: 47	
	AbstractSubscription.parseSelector(ConsumerInfo) line: 66	
	TopicSubscription(AbstractSubscription).<init>(Broker, ConnectionContext,
ConsumerInfo) line: 60	
	TopicSubscription.<init>(Broker, ConnectionContext, ConsumerInfo,
UsageManager) line: 70	
	ManagedTopicRegion(TopicRegion).createSubscription(ConnectionContext,
ConsumerInfo) line: 231	
	ManagedTopicRegion.createSubscription(ConnectionContext, ConsumerInfo)
line: 44	
	ManagedTopicRegion(AbstractRegion).addConsumer(ConnectionContext,
ConsumerInfo) line: 201	
	ManagedTopicRegion(TopicRegion).addConsumer(ConnectionContext,
ConsumerInfo) line: 110	
	ManagedRegionBroker(RegionBroker).addConsumer(ConnectionContext,
ConsumerInfo) line: 340	
	TransactionBroker(BrokerFilter).addConsumer(ConnectionContext,
ConsumerInfo) line: 86	
	AdvisoryBroker.addConsumer(ConnectionContext, ConsumerInfo) line: 78	
	CompositeDestinationBroker(BrokerFilter).addConsumer(ConnectionContext,
ConsumerInfo) line: 86	
	BrokerService$2(MutableBrokerFilter).addConsumer(ConnectionContext,
ConsumerInfo) line: 96	

ManagedTransportConnection(TransportConnection).processAddConsumer(ConsumerInfo)
line: 586	
	ConsumerInfo.visit(CommandVisitor) line: 313	
	ManagedTransportConnection(TransportConnection).service(Command) line: 294	
	TransportConnection$1.onCommand(Object) line: 185	
	MutexTransport(TransportFilter).onCommand(Object) line: 65	
	WireFormatNegotiator.onCommand(Object) line: 133	
	InactivityMonitor.onCommand(Object) line: 122	
	TcpTransport(TransportSupport).doConsume(Object) line: 84	
	TcpTransport.run() line: 137	
	Thread.run() line: 619	

And this test case I've written on the selector also gets the error

org.apache.activemq.selector
    public void testEmptySelector() throws Exception {
        Message message = createMessage();
        assertSelector(message, "", true);
    }

Is this a bug or am I doing something wrong? (4.1.1 release)
/Stefan

-- 
View this message in context: http://www.nabble.com/Empty-message-selector-throws-InvalidSelectorException-tf4377911s2354.html#a12478790
Sent from the ActiveMQ - Dev mailing list archive at Nabble.com.


Mime
View raw message