users@glassfish.java.net

Re: Null pointer exception when attempting to deploy simple JMS application(s)

From: <glassfish_at_javadesktop.org>
Date: Thu, 30 Sep 2010 14:50:13 PDT

Hello,

Sorry for the delay in getting back to you.

I reset the JMS Service type from LOCAL to EMBEDDED through the web administrator, renamed the logs you asked for and shut down the server. When I restarted the server all was good. I deployed my application with no issues.

The other day when I was having the issue with JMS I noticed that the lock file located in domain/imq/imqbroker was dated Aug 16 2010, which was about the time that I had last successfully deployed and run a JMS application. I thought it strange that this was so old since I had obviously stopped and started the Web Server (and JVM) numerous times since then. I renamed the lock file and continued to try to figure out what was wrong. In my haste to get past this issue I guess I must have changed the JMS type to LOCAL without pursuing the probability that the lock file could be the issue.

When I just ran the last test I kept an eye on the lock file. It was deleted when I shut down the service and a new file was created when the server was restarted. I bounced the server again, keeping the JMS type at EMBEDDED and the lock file cleared and was recreated as should be expected.

So, in conclusion I guess the null pointer issue was caused because the JMS service would not start because the stuck lock file indicated that there was already an instance of imqbroker running. If anyone else has this problem you should check the lock file because the broker will not start if the file is present.

Of course the question is why did the lock file get stuck in the first place or even better why does it hang around after the JVM ceases running when obviously no broker is running.

Thank you for your help in this matter.
[Message sent by forum member 'wnorman']

http://forums.java.net/jive/thread.jspa?messageID=484067