Re: [JBoss-user] JMS behind a firewall.
This simply means that the local address/port you want to bind the client socket to is already in use. If the connections are being created too quickly then the os may not be cleaning up the local address for reuse or there is an unclean close that is leaving the local socket in a fin wait state and preventing reuse. There is no difference between UIL2 and UIL in this reguard, except that the UIL uses the poorly named org.jboss.mq.il.oil.localPort and org.jboss.mq.il.oil.localAddr for the associated system properties so perhaps you were not really setting them. Why does the local client have to be bound to a specific port? You may need a pool manager to ensure there is only one valid jms connection if a specific client address/port is required to get through the firewall rather than opening/closing the connection every time. -- Scott Stark Chief Technology Officer JBoss Group, LLC Lyvers, William wrote: Nice catch Scott. That stack trace was coming from a hot deployment of jbossmq-service.xml to change from UIL2 to UIL without changing the JNDI name. I copied and pasted the wrong stack trace. Sorry for the mistake. The real stack trace from my UIL2 problem is below. The UIL2 works a couple of times. The client then starts to get this exception. ERROR Jul 11 17:48:55 [ddk.j2ee.FWAEventSender] - Exception:org.jboss.mq.SpyJMSException: Cannot authenticate user; - nested throwable: (java.net.SocketException: errno: 125, error: Address already in use for fd: 56) at org.jboss.mq.Connection.authenticate(Connection.java:883) at org.jboss.mq.Connection.(Connection.java:238) at org.jboss.mq.SpyConnection.(SpyConnection.java:48) at org.jboss.mq.SpyConnectionFactory.createQueueConnection(SpyConnectionFactory.java:135) at com.fusura.xcs.ddk.j2ee.FWAEventSender.sendMessage(FWAEventSender.java:180) at com.fusura.xcs.ddk.j2ee.FWAEventSender.sendDispositionEvent(FWAEventSender.java:157) at com.fusura.xcs.southsea.csr.DispositionFormHandler.handleUpdate(DispositionFormHandler.java:68) at java.lang.reflect.Method.invoke(Native Method) at atg.droplet.EventSender.sendEvent(EventSender.java:528) at atg.droplet.FormTag.doSendEvents(FormTag.java:687) at atg.droplet.FormTag.sendEvents(FormTag.java:592) at atg.droplet.DropletEventServlet.sendEvents(DropletEventServlet.java:245) at atg.droplet.DropletEventServlet.service(DropletEventServlet.java:262) at atg.servlet.pipeline.PipelineableServletImpl.service(PipelineableServletImpl.java:224) at atg.servlet.pipeline.DispatcherPipelineServletImpl.service(DispatcherPipelineServletImpl.java:146) at atg.servlet.pipeline.PipelineableServletImpl.passRequest(PipelineableServletImpl.java:114) at atg.servlet.pipeline.MimeTyperPipelineServlet.service(MimeTyperPipelineServlet.java:204) at atg.servlet.pipeline.PipelineableServletImpl.passRequest(PipelineableServletImpl.java:114) at atg.servlet.pipeline.FileFinderPipelineServlet.service(Unknown Source) at atg.servlet.pipeline.PipelineableServletImpl.passRequest(PipelineableServletImpl.java:114) at atg.servlet.pipeline.DispatcherPipelineServletImpl.service(DispatcherPipelineServletImpl.java:163) at atg.servlet.pipeline.PipelineableServletImpl.passRequest(PipelineableServletImpl.java:114) at atg.servlet.CgiServlet.serviceRequest(Unknown Source) at atg.servlet.CgiServlet.service(Unknown Source) at atg.servlet.pipeline.PipelineableServletImpl.passRequest(PipelineableServletImpl.java:114) at atg.servlet.pipeline.WebApplicationDispatcherPipelineServlet.service(WebApplicationDispatcherPipelineServlet.java:64) at atg.servlet.pipeline.PipelineableServletImpl.passRequest(Pipelineabl --- This SF.Net email sponsored by: Parasoft Error proof Web apps, automate testing & more. Download & eval WebKing and get a free book. www.parasoft.com/bulletproofapps1 ___ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] JMS behind a firewall.
Nice catch Scott. That stack trace was coming from a hot deployment of jbossmq-service.xml to change from UIL2 to UIL without changing the JNDI name. I copied and pasted the wrong stack trace. Sorry for the mistake. The real stack trace from my UIL2 problem is below. The UIL2 works a couple of times. The client then starts to get this exception. ERROR Jul 11 17:48:55 [ddk.j2ee.FWAEventSender] - Exception:org.jboss.mq.SpyJMSException: Cannot authenticate user; - nested throwable: (java.net.SocketException: errno: 125, error: Address already in use for fd: 56) at org.jboss.mq.Connection.authenticate(Connection.java:883) at org.jboss.mq.Connection.(Connection.java:238) at org.jboss.mq.SpyConnection.(SpyConnection.java:48) at org.jboss.mq.SpyConnectionFactory.createQueueConnection(SpyConnectionFactory.java:135) at com.fusura.xcs.ddk.j2ee.FWAEventSender.sendMessage(FWAEventSender.java:180) at com.fusura.xcs.ddk.j2ee.FWAEventSender.sendDispositionEvent(FWAEventSender.java:157) at com.fusura.xcs.southsea.csr.DispositionFormHandler.handleUpdate(DispositionFormHandler.java:68) at java.lang.reflect.Method.invoke(Native Method) at atg.droplet.EventSender.sendEvent(EventSender.java:528) at atg.droplet.FormTag.doSendEvents(FormTag.java:687) at atg.droplet.FormTag.sendEvents(FormTag.java:592) at atg.droplet.DropletEventServlet.sendEvents(DropletEventServlet.java:245) at atg.droplet.DropletEventServlet.service(DropletEventServlet.java:262) at atg.servlet.pipeline.PipelineableServletImpl.service(PipelineableServletImpl.java:224) at atg.servlet.pipeline.DispatcherPipelineServletImpl.service(DispatcherPipelineServletImpl.java:146) at atg.servlet.pipeline.PipelineableServletImpl.passRequest(PipelineableServletImpl.java:114) at atg.servlet.pipeline.MimeTyperPipelineServlet.service(MimeTyperPipelineServlet.java:204) at atg.servlet.pipeline.PipelineableServletImpl.passRequest(PipelineableServletImpl.java:114) at atg.servlet.pipeline.FileFinderPipelineServlet.service(Unknown Source) at atg.servlet.pipeline.PipelineableServletImpl.passRequest(PipelineableServletImpl.java:114) at atg.servlet.pipeline.DispatcherPipelineServletImpl.service(DispatcherPipelineServletImpl.java:163) at atg.servlet.pipeline.PipelineableServletImpl.passRequest(PipelineableServletImpl.java:114) at atg.servlet.CgiServlet.serviceRequest(Unknown Source) at atg.servlet.CgiServlet.service(Unknown Source) at atg.servlet.pipeline.PipelineableServletImpl.passRequest(PipelineableServletImpl.java:114) at atg.servlet.pipeline.WebApplicationDispatcherPipelineServlet.service(WebApplicationDispatcherPipelineServlet.java:64) at atg.servlet.pipeline.PipelineableServletImpl.passRequest(Pipelineabl -Original Message- From: Scott M Stark [mailto:[EMAIL PROTECTED] Sent: Friday, July 11, 2003 12:35 PM To: [EMAIL PROTECTED] Subject: Re: [JBoss-user] JMS behind a firewall. The previous message shown an exception due to the jms destination being shutdown due undeployment of the destination service descriptor. This cannot be triggered by the close of the jms connection so how is that coming about? Scott Stark Chief Technology Officer JBoss Group, LLC On Friday, July 11, 2003, at 06:11 AM, Lyvers, William wrote: > Hauer, > > This is the code that is executing on each request. At this point in > time, we haven't even began caching off the context and such. One > thing that I did notice, is that we are binding the clients to one > port using the org.jboss.mq.il.uil2.localAddr and > org.jboss.mq.il.uil2.localPort system properites from the client side. > I am not sure if this would make a difference, since we are doing > this for uil as well. I haven't had a chance to test taking these > properties out. I believe we were originally setting these when > trying to get through our firewall. > > > InitialContext iniCtx = new InitialContext( env ); > QueueConnectionFactory qcf = (QueueConnectionFactory) > iniCtx.lookup( QUEUE_CONNECTION_FACTORY ); > QueueConnection conn = > qcf.createQueueConnection(USERID,PASSWORD); > Queue que = (Queue) iniCtx.lookup(EVENT_QUEUE); > QueueSession session = conn.createQueueSession(false, > QueueSession.AUTO_ACKNOWLEDGE); > conn.start(); > QueueSender send = session.createSender(que); > ObjectMessage om = session.createObjectMessage( message ); > > om.setStringProperty ("MessageTy
Re: [JBoss-user] JMS behind a firewall.
The previous message shown an exception due to the jms destination being shutdown due undeployment of the destination service descriptor. This cannot be triggered by the close of the jms connection so how is that coming about? Scott Stark Chief Technology Officer JBoss Group, LLC On Friday, July 11, 2003, at 06:11 AM, Lyvers, William wrote: Hauer, This is the code that is executing on each request. At this point in time, we haven't even began caching off the context and such. One thing that I did notice, is that we are binding the clients to one port using the org.jboss.mq.il.uil2.localAddr and org.jboss.mq.il.uil2.localPort system properites from the client side. I am not sure if this would make a difference, since we are doing this for uil as well. I haven't had a chance to test taking these properties out. I believe we were originally setting these when trying to get through our firewall. InitialContext iniCtx = new InitialContext( env ); QueueConnectionFactory qcf = (QueueConnectionFactory) iniCtx.lookup( QUEUE_CONNECTION_FACTORY ); QueueConnection conn = qcf.createQueueConnection(USERID,PASSWORD); Queue que = (Queue) iniCtx.lookup(EVENT_QUEUE); QueueSession session = conn.createQueueSession(false, QueueSession.AUTO_ACKNOWLEDGE); conn.start(); QueueSender send = session.createSender(que); ObjectMessage om = session.createObjectMessage( message ); om.setStringProperty ("MessageType", messageType ); send.send(om); send.close(); conn.stop(); session.close(); conn.close(); Thanks, Billy --- This SF.Net email sponsored by: Parasoft Error proof Web apps, automate testing & more. Download & eval WebKing and get a free book. www.parasoft.com/bulletproofapps1 ___ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] JMS behind a firewall.
Hauer, This is the code that is executing on each request. At this point in time, we haven't even began caching off the context and such. One thing that I did notice, is that we are binding the clients to one port using the org.jboss.mq.il.uil2.localAddr and org.jboss.mq.il.uil2.localPort system properites from the client side. I am not sure if this would make a difference, since we are doing this for uil as well. I haven't had a chance to test taking these properties out. I believe we were originally setting these when trying to get through our firewall. InitialContext iniCtx = new InitialContext( env ); QueueConnectionFactory qcf = (QueueConnectionFactory) iniCtx.lookup( QUEUE_CONNECTION_FACTORY ); QueueConnection conn = qcf.createQueueConnection(USERID,PASSWORD); Queue que = (Queue) iniCtx.lookup(EVENT_QUEUE); QueueSession session = conn.createQueueSession(false, QueueSession.AUTO_ACKNOWLEDGE); conn.start(); QueueSender send = session.createSender(que); ObjectMessage om = session.createObjectMessage( message ); om.setStringProperty ("MessageType", messageType ); send.send(om); send.close(); conn.stop(); session.close(); conn.close(); Thanks, Billy -Original Message- From: Sebastian Hauer [mailto:[EMAIL PROTECTED] Sent: Thursday, July 10, 2003 4:23 PM To: [EMAIL PROTECTED] Subject: RE: [JBoss-user] JMS behind a firewall. Hi William, > connection after sending the message. When we use the UIL > invocation layer, the exception does not occur. The client > is a servlet that establishes a connection each time, sends a > message then closes out the connection. Are clients only > allowed to establish one connection with the UIL2 layer? > > - Destroying failedjavax.jms.JMSException: The destination > is being used. > at > org.jboss.mq.server.JMSDestinationManager.closeDestination(JMS > DestinationManager.java:804) > at > org.jboss.mq.server.jmx.DestinationMBeanSupport.destroyService > (DestinationMBeanSupport.java:122) Not that I know of, you should be able to open as may connection as you want. Can you show some code how you open and use the connection? Regards, Sebastian --- This SF.Net email sponsored by: Parasoft Error proof Web apps, automate testing & more. Download & eval WebKing and get a free book. www.parasoft.com/bulletproofapps1 ___ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user --- This SF.Net email sponsored by: Parasoft Error proof Web apps, automate testing & more. Download & eval WebKing and get a free book. www.parasoft.com/bulletproofapps1 ___ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] JMS behind a firewall.
Hi William, > connection after sending the message. When we use the UIL > invocation layer, the exception does not occur. The client > is a servlet that establishes a connection each time, sends a > message then closes out the connection. Are clients only > allowed to establish one connection with the UIL2 layer? > > - Destroying failedjavax.jms.JMSException: The destination > is being used. > at > org.jboss.mq.server.JMSDestinationManager.closeDestination(JMS > DestinationManager.java:804) > at > org.jboss.mq.server.jmx.DestinationMBeanSupport.destroyService > (DestinationMBeanSupport.java:122) Not that I know of, you should be able to open as may connection as you want. Can you show some code how you open and use the connection? Regards, Sebastian --- This SF.Net email sponsored by: Parasoft Error proof Web apps, automate testing & more. Download & eval WebKing and get a free book. www.parasoft.com/bulletproofapps1 ___ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] JMS behind a firewall.
Thanks, We have the Http invoker layer working, but we are getting the following exception when using the UIL2 invocation layer. It looks to be occurring when the client tries to close the connection after sending the message. When we use the UIL invocation layer, the exception does not occur. The client is a servlet that establishes a connection each time, sends a message then closes out the connection. Are clients only allowed to establish one connection with the UIL2 layer? - Destroying failedjavax.jms.JMSException: The destination is being used. at org.jboss.mq.server.JMSDestinationManager.closeDestination(JMSDestinationManager.java:804) at org.jboss.mq.server.jmx.DestinationMBeanSupport.destroyService(DestinationMBeanSupport.java:122) at org.jboss.system.ServiceMBeanSupport.destroy(ServiceMBeanSupport.java:271) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:324) at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284) at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:549) at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:966) at $Proxy11.destroy(Unknown Source) at org.jboss.system.ServiceController.destroy(ServiceController.java:521) at org.jboss.system.ServiceController.destroy(ServiceController.java:513) at org.jboss.system.ServiceController.destroy(ServiceController.java:513) at org.jboss.system.ServiceController.destroy(ServiceController.java:513) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:324) at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284) at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:549) at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:177) at $Proxy5.destroy(Unknown Source) at org.jboss.deployment.SARDeployer.destroy(SARDeployer.java:424) at org.jboss.deployment.MainDeployer.destroy(MainDeployer.java:530) at org.jboss.deployment.MainDeployer.undeploy(MainDeployer.java:481) at org.jboss.deployment.MainDeployer.undeploy(MainDeployer.java:475) at org.jboss.deployment.MainDeployer.undeploy(MainDeployer.java:448) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:324) at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284) at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:549) at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:177) at $Proxy7.undeploy(Unknown Source) at org.jboss.deployment.scanner.URLDeploymentScanner.undeploy(URLDeploymentScanner.java:310) at org.jboss.deployment.scanner.URLDeploymentScanner.scan(URLDeploymentScanner.java:406) at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.doScan(AbstractDeploymentScanner.java:200) at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.loop(AbstractDeploymentScanner.java:211) at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.run(AbstractDeploymentScanner.java:190) -Original Message- From: Sebastian Hauer [mailto:[EMAIL PROTECTED] Sent: Tuesday, July 08, 2003 6:37 PM To: [EMAIL PROTECTED] Subject: RE: [JBoss-user] JMS behind a firewall. Hi Billy, You can tunnel all your RMI calls through HTTP/S, this would include JNDI lookup calls. So you would only need one port for that and than use something like UIL or better UIL2 for JMS which will also need just one port. We have a setup like this in production using JBoss 3.0.x. Regards, Sebastian --- This SF.Net email sponsored by: Parasoft Error proof Web apps, automate testing & more. Download & eval WebKing and get a free book. www.parasoft.com/bulletproofapps ___ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user --- This SF.Net email sponsored by: Parasoft Err
RE: [JBoss-user] JMS behind a firewall.
Hi Billy, You can tunnel all your RMI calls through HTTP/S, this would include JNDI lookup calls. So you would only need one port for that and than use something like UIL or better UIL2 for JMS which will also need just one port. We have a setup like this in production using JBoss 3.0.x. Regards, Sebastian --- This SF.Net email sponsored by: Parasoft Error proof Web apps, automate testing & more. Download & eval WebKing and get a free book. www.parasoft.com/bulletproofapps ___ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user