0 Replies Latest reply on Oct 20, 2009 11:21 PM by dthurst

    Setting socket timeout on ActionScriptAdapter?

    dthurst

      I have an application that is using BlazeDS for two-way communication between a Java-based server hosted on Tomcat and a Flex Client.  From one particular client access location (and no others we've seen), the server is throwing a java.net.SocketTimeoutException as shown in the Stack trace below.

       

      I believe I could solve the problem by increasing the socket timeout setting, but I can't find where to do this.  I am using a subclass of ActionScriptAdapter which, unlike the HTTPProxyAdapter, does not appear to accept an HTTPConnectionManagerSettings object to specify the timeout.

       

      I am thinking I may be able to set this value via the initialize( id , ConfigMap ) method, but have found no documentation on the allowable properties that can go in the ConfigMap argument.

       

      Any help greatly appreciated.  Partial stack trace for the error is below:

       

      [BlazeDS]Read timed out

      java.net.SocketTimeoutException: Read timed out

      at java.net.SocketInputStream.socketRead0(Native Method)

      at java.net.SocketInputStream.read(SocketInputStream.java:146)

      at org.apache.coyote.http11.InternalInputBuffer.fill(InternalInputBuffer.java:748)

      at org.apache.coyote.http11.InternalInputBuffer$InputStreamInputBuffer.doRead(InternalInputB uffer.java:778)

      at org.apache.coyote.http11.filters.IdentityInputFilter.doRead(IdentityInputFilter.java:116)

      at org.apache.coyote.http11.InternalInputBuffer.doRead(InternalInputBuffer.java:713)

      at org.apache.coyote.Request.doRead(Request.java:419)

      at org.apache.catalina.connector.InputBuffer.realReadBytes(InputBuffer.java:265)

      at org.apache.tomcat.util.buf.ByteChunk.substract(ByteChunk.java:370)

      at org.apache.catalina.connector.InputBuffer.readByte(InputBuffer.java:274)

      at org.apache.catalina.connector.CoyoteInputStream.read(CoyoteInputStream.java:105)

      at java.io.DataInputStream.readUnsignedShort(DataInputStream.java:337)

      at flex.messaging.io.amf.AbstractAmfInput.readUnsignedShort(AbstractAmfInput.java:172)

      at flex.messaging.io.amf.AmfMessageDeserializer.readMessage(AmfMessageDeserializer.java:88)

      at flex.messaging.endpoints.amf.SerializationFilter.invoke(SerializationFilter.java:114)

      at flex.messaging.endpoints.BaseHTTPEndpoint.service(BaseHTTPEndpoint.java:274)

      at flex.messaging.MessageBrokerServlet.service(MessageBrokerServlet.java:377)

      at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)

      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.j ava:269)

      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)