Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7583213
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T18:37:34+00:00 2026-05-30T18:37:34+00:00

The tomcat connection pool has a setting called maxActive and a setting called maxIdle

  • 0

The tomcat connection pool has a setting called maxActive and a setting called maxIdle my questions are.

  1. What is the difference between these two settings?
  2. What is a real world example scenario where you might have a different value for maxActive than you would for maxIdle?

For some reason the docs are not making sense to me. maxActive and maxIdle exist on both the apache dbcp and the tomact 7 jdbc-pool according to the docs at
http://tomcat.apache.org/tomcat-7.0-doc/jdbc-pool.html

maxActive (int) The maximum number of active connections that can be
allocated from this pool at the same time. The default value is 100

maxIdle (int) The maximum number of connections that should be kept
in the pool at all times. Default value is maxActive:100 Idle
connections are checked periodically (if enabled) and connections that
been idle for longer than minEvictableIdleTimeMillis will be released.
(also see testWhileIdle)

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-30T18:37:35+00:00Added an answer on May 30, 2026 at 6:37 pm

    maxActive is straight forward. maxIdle can be explained in this way – say you have 100 max Active connections and say you set maxIdle to 80. Assuming there are no requests going to the database, only 80 connections will be tested (via the validationquery) and will stay active. The other 20 will be closed. So at any point you can only have 80 idle connections.
    You might want to set this to be a different number to prevent additional (unnecessary) connections going out to the database. Cos every connection that is served by the database consumes resources (like memory).
    But, assuming you have set the maxActive size to 100 and all 100 are in use almost all the time, this setting will obviously not matter.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am getting Following Exception while configuring the Connection Pool in Tomcat This is
I have set up Tomcat to use a connection pool yet after the MySQL
I'm trying to configure Apache Tomcat to use SSL connection with client authentication (two
I'm investigating moving away from an Oracle connection pool and using the Tomcat connection
What are Maven coordinates of Tomcat JDBC Connection Pool ?
I have a connection pool set in the tomcat server context.xml (connection used by
I'm recntly doing some tests with the new Tomcat JDBC connection pool ( org.apache.tomcat.jdbc.pool
This article suggests Tomcat 7 apps should use a JDBC connection pool instead of
I really am having a nightmare configuring Tomcat to set up a connection pool.
I have a tomcat instance setup but the database connection I have configured in

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.