dcsimg
javax.jms.InvalidDestinationException
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Karl_Powell
Posted On:   Wednesday, July 17, 2002 01:36 PM

I'm having an intermitent problem with SwiftMQ v2.1.3. I've looked through the postings, but have yet to find a matching thread. I have a Java 1.3.0 class that looks up a JNDI entry based on a standard alias name. Several servers are running the same code, so they all look up the same alias, but each router has a different value associated to the alias. (And each server only has a single router, and the router's name matches the server's name.) The alias value is used to create a queue receiver on the local router. However, I intermitently receive this error (with the obvious value substitutions): javax.jms.InvalidDestinationException: Queue 'queuename@hostname' is not local! Can't create a Co   More>>

I'm having an intermitent problem with SwiftMQ v2.1.3. I've looked through the postings, but have yet to find a matching thread.



I have a Java 1.3.0 class that looks up a JNDI entry based on a standard alias name. Several servers are running the same code, so they all look up the same alias, but each router has a different value associated to the alias. (And each server only has a single router, and the router's name matches the server's name.)



The alias value is used to create a queue receiver on the local router. However, I intermitently receive this error (with the obvious value substitutions):



javax.jms.InvalidDestinationException: Queue 'queuename@hostname' is not local! Can't create a Consumer on it!



It usually works, but will at times throw a single instance of this error or start continuously throwing this error until the router is restarted. Additionally, the JNDI lookup may resolve to an alias's value from another of the routers (which, of course, throws errors since you can't create a consumer to a non-local router).



I've found in the 2.1.3 docs that a JNDI session will be shared from another router if the local one is unavailable. This would explain this secondary behavior, but it doesn't help explain the primary issue.



If anyone has seen this connection problem to a the local router before, I would greatly appreciate some input. The documentation, JGuru, and Deja are not leading anywhere useful.



Also, is there a way to disable the sharing of JNDI information between routers?

   <<Less

Re: javax.jms.InvalidDestinationException

Posted By:   Andreas_Mueller  
Posted On:   Wednesday, July 17, 2002 02:18 PM

If you use the same JNDI alias, all routers will respond on the lookup and you may get a remote queue. Usually the local JNDI Swiftlet is the fastest in response, however, it is not guaranteed. You might use qualified queue names instead of aliases to force the local queues.
About | Sitemap | Contact