<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div>On Aug 9, 2010, at 12:47 PM, archana v wrote:</div><div><br class="Apple-interchange-newline"><blockquote type="cite">Thanks for your reply.I am not using spring.. I am trying to configure it at servlet init. But it doesn seem to work. I dont know if my method of declaring the listener is right. It would be helpful if you could send me some samples.</blockquote><div><br></div>Sorry, I don't have any example of using servlet init because I use Spring.</div><div><br></div><div>Maybe you could show a little of what you're trying to do?</div><div><br></div><div>Are you including <load-on-startup>1</load-on-startup> in your servlet init?</div><div><br></div><div>jb</div><div><br></div><div><br><blockquote type="cite"><div>
<br></div><div><br></div><div>Thanks and Regards,</div><div>Archana <br><br><div class="gmail_quote">On Mon, Aug 9, 2010 at 1:43 PM, Jon Brisbin <span dir="ltr"><<a href="mailto:jon.brisbin@npcinternational.com">jon.brisbin@npcinternational.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div style="word-wrap:break-word">There's actually a lot of ways to go about this:<div><br></div><div>1) If you're using Spring, then just configure a bean in your app-context.xml. </div>
<div><br></div><div>2) You could use the new spring-amqp classes: <a href="http://www.springsource.org/spring-amqp" target="_blank">http://www.springsource.org/spring-amqp</a><div><br></div><div><a href="http://www.springsource.org/spring-amqp" target="_blank"></a>3) You could manually configure them from the servlet init method.</div>
<div><br></div><div>I also run listeners that integrate with the Tomcat server. You can configure them in different ways depending on the context. You could set up a global naming resource, or you could scope it to your web application by putting it in META-INF/context.xml: <a href="http://tomcat.apache.org/tomcat-6.0-doc/jndi-resources-howto.html" target="_blank">http://tomcat.apache.org/tomcat-6.0-doc/jndi-resources-howto.html</a><br>
<div>
<div><div><br>Jon Brisbin</div><div>Portal Webmaster</div><div>NPC International, Inc.</div><br></div><br>
</div>
<br><div><div><div></div><div class="h5"><div>On Aug 9, 2010, at 11:33 AM, archana v wrote:</div><br></div></div><blockquote type="cite"><div><div></div><div class="h5"><span style="font-family:arial, sans-serif;font-size:13px;border-collapse:collapse">Hi All,</span><div style="font-family:arial, sans-serif;font-size:13px;border-collapse:collapse">
<br></div><div style="font-family:arial, sans-serif;font-size:13px;border-collapse:collapse">I am new to rabbit-mq. I would like to know how to start a MQ listner(Java Client) to listen to a queue at the application start up. I am deploying my application in tomcat server.</div>
<span style="font-family:arial, sans-serif;font-size:13px;border-collapse:collapse">
</span><div style="font-family:arial, sans-serif;font-size:13px;border-collapse:collapse">Thanks in advance for your help.</div><div style="font-family:arial, sans-serif;font-size:13px;border-collapse:collapse"><br></div>
<div style="font-family:arial, sans-serif;font-size:13px;border-collapse:collapse"><br></div><div style="font-family:arial, sans-serif;font-size:13px;border-collapse:collapse">Thanks and Regards,</div><div style="font-family:arial, sans-serif;font-size:13px;border-collapse:collapse">
Archana </div></div></div>
_______________________________________________<br>rabbitmq-discuss mailing list<br><a href="mailto:rabbitmq-discuss@lists.rabbitmq.com" target="_blank">rabbitmq-discuss@lists.rabbitmq.com</a><br><a href="https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss" target="_blank">https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss</a><br>
</blockquote></div><br></div></div></div></blockquote></div><br></div>
</blockquote></div><br></body></html>