tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christopher Schultz <ch...@christopherschultz.net>
Subject Re: Avoiding/Handling SocketTimeoutException(s) when web application serving resources to mobile clients
Date Mon, 11 Nov 2013 15:23:06 GMT
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Howard,

On 11/10/13, 9:25 AM, Howard W. Smith, Jr. wrote:
> On Sun, Nov 10, 2013 at 9:14 AM, Howard W. Smith, Jr. < 
> smithh032772@gmail.com> wrote:
> 
>> Caused by: java.net.SocketTimeoutException at 
>> org.apache.tomcat.util.net.NioBlockingSelector.write(NioBlockingSelector.java:127)
>>
>> 
at
>> org.apache.tomcat.util.net.NioSelectorPool.write(NioSelectorPool.java:174)
>>
>> 
at
>> org.apache.coyote.http11.InternalNioOutputBuffer.writeToSocket(InternalNioOutputBuffer.java:163)
>>
>
>> 
> my apologies, based on this exception (above), I decided to provide
> you with the following from my tomee/conf/server.xml:
> 
> 
> <Connector port="8080" 
> protocol="org.apache.coyote.http11.Http11NioProtocol" 
> maxThreads="150" connectionTimeout="20000" acceptorThreadCount="2" 
> redirectPort="8443" socket.directBuffer="false"/>
> 
> 
> I guess the answer may be the connectionTimeout="..." (above), but
> still would like to know recommendations of others based on
> experience with web application serving mobile clients. thanks.

I might recommend using a Filter like this:

filter() {
   try {
     chain.doFilter();
   } catch (SocketTimeoutException ste) {
     application.log("Got STE for request " + request.getRequestURI()
+ with client " + request.getHeader("User-Agent"));
   }
}

... or something like that. It might help uncover patterns in dropped
connections. Maybe Igor is right and the problem is some browser (e.g.
MSIE 8) and not necessarily mobile clients.

- -chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.15 (Darwin)
Comment: GPGTools - http://gpgtools.org
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQIcBAEBCAAGBQJSgPZaAAoJEBzwKT+lPKRYhQoQAKgd26kNQJzv+9GDrJLlDTWk
1c0GCYjLT6ckC4J5cUbnStznl8OeGg6Qyxvk9uN02WKUNtAqfWbbd7LE7B/0zoZp
UiM88GmhMWZNG2ezsX2pn9yJ0CNqTLkVmPPLf6vyxC/FACXb10ACM0MOeCKHQ+pb
+IsX0IPfyvz3TieLWM89cJboHAHn/4Pt6yBvdi/6IBzD8jKzOk1XsGcfwP2Qwq6j
up1U6oer2T6AidhNIrZ1yUStFe1vIujh3FwCmRM9FIgDNeeIrBPkOzMG8TTDju7a
Z7Q1h3xu7gtbh6r/zSM9uj9q2SaunJorOVISrwINZTRSm19UMafzUEzUz6Mz3KNw
XJzVV7Q3gez2pbKwwxOkBlmqXx2JTFPk2Q6Llwddcg7rx5XWg7MOyM/JuYOaQcby
h/ZIkOltZDP9AA2JJMaitay+GJIZiZu0B9ZXtD4snGkZt4+4VouRQi0LE9lNOVgH
8I4W3tcQAo/CExufvtQVJQk/QwE+DFbBtPdNua99qBrtiubtBOHJHTMMMseaj6Ic
cyzGzGR6Y7xOGHb4RzxnjLTFuBLTfsmNC9P2f3362MICIMnMpGQBIrkIydzhIsPI
KEC+gvoS9J1V1JUzwCjwCY3AZc6d7YjF0ubChdjcN5Is3dLECkE1UCiPCNXRiTS/
0YR4TBnfnzIBMlvqY5+D
=ogzq
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message