Hi I am trying to create a sender JSP page using JMS and it creates a text message "Update" if the request attribute is "prodRequest". If not, then a message with the shopping cart contents are sent to the Queue. I can see that the message is getting created but it is not sent to the queue. Could you please help me find my mistake!
I'll post the code for the queue receiver program if somebody wants to check if that has errors in it! Thanks in advance Vidya
First of all, thanks for your response. Second of all, sorry for the delay in posting the answers to your questions. How do you know that your messages are not posted to the Queue? -->The messages seem to be posted to the queue Do you have a monitoring tool to see if there are messages in the queue? -->I have the MQ series explorer
What output do you see in the server logs? Does your JVM (Server) terminate when you run your program(JSP)? -->The statements which I print in the System.out are printed to the server log. The JVM doesn't terminate when I run the JSP. I have one more question for you. Is it possible to write this queue sender and receiver in a Java program. How do I call that program from a jsp page? Thanks Vidya
Amit M Tank
Joined: Mar 28, 2004
-->I have the MQ series explorer
So you must be able to see if the messages are there in the Queue.
-->The statements which I print in the System.out are printed to the server log. The JVM doesn't terminate when I run the JSP. I have one more question for you. Is it possible to write this queue sender and receiver in a Java program. How do I call that program from a jsp page?
I asked that question because I saw in your code. I guess you should remove that from your code as it will bring down the entire server in case of an Exception.
yes you can write the Sender and receiver in a java program and call that program from your JSP file. You just need to import those classes (sender and receiver) in the JSP and call the appropriate method in the scriplet. However, using scriplet is an old way of doing stuff in JSP, but if you are just working out examples then it is okay to use scriplets in JSP.
subject: Message is created but not received by the receiver