• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Darned Connector Settings

 
Greenhorn
Posts: 29
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello everyone,

I'm having a hard time configuring Tomcat. Seems like all effort I do results in memory errors after some hours.

What I want to understand is what exactly all connector settings stands for.

i.e.

maxThreads
acceptCount
connectionTimeout
minSpareThreads
maxSpareThreads
minProcessors
maxProcessors

my current setting is:



<Connector port="80" maxHttpHeaderSize="8192"
maxThreads="30" minSpareThreads="10" maxSpareThreads="10"
enableLookups="false" redirectPort="8443" acceptCount="30"
connectionTimeout="8000" disableUploadTimeout="true"
compression="on"
compressionMinSize="12000"
compressableMimeType="text/html,text/xml"


/>



I used to use the setting above with only 500MB in our server. But we got this upgrade to 1GB of RAM. The config above handled 1 or 2 days of uptime, with some latency at the rush hour. So, I thought it would be nice to "tune up" our server in order to use the additional memory better.

So I tried the config bellow. The app runned smoothly and fast with this new configuration, but crashed after 8h of up time. Generating out of memory errors.




I'm starting the server with those options:


JAVA_OPTS="-Xms350M -Xmx750M -verbose:gc -XX:+PrintGCDetails";

 
Sheriff
Posts: 67746
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Sounds more like a memory leak in your program rather than a config issue.
 
Fabio Fonseca
Greenhorn
Posts: 29
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Bear,

memory solved the problem. Just to turn our app on costs 420MB. Yesterday, by using the old configuration we handled all incoming smoothly.

But I still want to understand the connector settings properly. I still don't get what those items stands for:

maxThreads
acceptCount
connectionTimeout
minSpareThreads
maxSpareThreads
minProcessors
maxProcessors
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic