pooling

Connection pooling with Java and MySQL in Tomcat web application

橙三吉。 提交于 2019-12-04 12:33:22
I recently wrote and deployed a Java web application to a server and I'm finding an unusual problem which didn't appear during development or testing. When a user logs in after so long and goes to display data from the database, the page indicates that there are no records to see. But upon page refresh, the first x records are shown according to the pagination rules. Checking the logs, I find: ERROR|19 09 2009|09 28 54|http-8080-4|myDataSharer.database_access.Database_Metadata_DBA| - Error getting types of columns of tabular Dataset 12 com.mysql.jdbc.CommunicationsException: Communications

Is there a standard way of implementing a proprietary connection pool in .net?

送分小仙女□ 提交于 2019-12-04 07:19:14
Is there a standard connection pooling model (or API) similar to that used by the data providers in .net that I could use to implement my own connection pool? I ask because I have a requirement to implement my own connection pool to a proprietary TCP/IP device that we use in a web service. The current problem is that there are lot of connections (read too many) to the device due to the threaded nature of web services running under IIS. I want to limit the number of these connections using my own connection pool and it seems stupid to reinvent the wheel if there is a standard model I could use

How to pool objects in Spring?

天涯浪子 提交于 2019-12-04 05:31:11
I'm following this tutorial regarding how to pool objects in Spring. I've followed the instruction written on the tutorial but when I run my application, it always generates a new instance of the object. I'm expecting that since I'm pooling the objects, existing objects will be reuse. As such, no new instances should be created. Also, when I access of the getter method of the bean, a new instance of the bean is created again. What could have I done wrong? Did I misunderstood the concept of pooling in Spring? Below is my code: Application Context: (This is just the body of my application

Thread Pool vs Many Individual Threads

隐身守侯 提交于 2019-12-04 03:59:53
I'm in the middle of a problem where I am unable decide which solution to take. The problem is a bit unique. Lets put it this way, i am receiving data from the network continuously (2 to 4 times per second). Now each data belongs to a different, lets say, group. Now, lets call these groups, group1, group2 and so on. Each group has a dedicated job queue where data from the network is filtered and added to its corresponding group for processing. At first I created a dedicated thread per group which would take data from the job queue, process it and then goes to blocking state (using Linked

Running out of DB connections!

夙愿已清 提交于 2019-12-03 09:32:59
问题 I'm running a Spring/Hibernate connecting to MySQL setup using c3p0 as my connection pool. For some bizarre reason it runs out of connections when the system is under load (of course). The site was pretty stable until we started hitting a new level of traffic (over a hundred concurrent users). At that point the DB would melt down (peg the CPU). My first action was in the application to improve performance through extensive caching and optimization of queries etc. Now it will just run out of

Best Method of Channel Pooling in Google App Engine

扶醉桌前 提交于 2019-12-03 03:43:57
问题 It seems the only way to make the GAE Channel API financially viable is to implement some kind of pooling mechanism (one of the senior app engine product managers even told me this when I emailed them about the exorbitant price) to reuse channels that have not yet expired. I've been brainstorming ways (places) to implement a channel pool, but each method I think of has some pretty serious drawbacks. Static memory of a Servlet -- Good, but will drop quite a bit of open channels when a new VM

Running out of DB connections!

烈酒焚心 提交于 2019-12-02 23:51:57
I'm running a Spring/Hibernate connecting to MySQL setup using c3p0 as my connection pool. For some bizarre reason it runs out of connections when the system is under load (of course). The site was pretty stable until we started hitting a new level of traffic (over a hundred concurrent users). At that point the DB would melt down (peg the CPU). My first action was in the application to improve performance through extensive caching and optimization of queries etc. Now it will just run out of connections intermittently. It doesn't even seem that dependent on load. More on time which makes me

Best Method of Channel Pooling in Google App Engine

你说的曾经没有我的故事 提交于 2019-12-02 15:59:06
It seems the only way to make the GAE Channel API financially viable is to implement some kind of pooling mechanism (one of the senior app engine product managers even told me this when I emailed them about the exorbitant price) to reuse channels that have not yet expired. I've been brainstorming ways (places) to implement a channel pool, but each method I think of has some pretty serious drawbacks. Static memory of a Servlet -- Good, but will drop quite a bit of open channels when a new VM instance opens and/or a client gets passed from one VM to another. Memcache -- At least the memory is

db connection pool across processes

假装没事ソ 提交于 2019-12-02 02:02:46
We have a client/server application that consists of multiple EXEs. The data access layer is on the same physical tier as the client in a library shared by our EXE modules. ODBC and OleDB connection pools are managed per-process; are there techniques for sharing DB connections across processes (other than moving the data access layer to a middle tier)? Database connections in OLEDB and ODBC are intrinsically process bound. At the lowest levels, a sql server database connection is using an IPC mechanism like named pipes, shared memory, or tcp sockets. Other databases probably use network

Tomcat Connection Pool Exhausted

血红的双手。 提交于 2019-12-01 04:18:24
I'm using Apache Tomcat JDBC connection pooling in my project. I'm confused because under heavy load I keep seeing the following error: 12:26:36,410 ERROR [] (http-/XX.XXX.XXX.X:XXXXX-X) org.apache.tomcat.jdbc.pool.PoolExhaustedException: [http-/XX.XXX.XXX.X:XXXXX-X] Timeout: Pool empty. Unable to fetch a connection in 10 seconds, none available[size:4; busy:4; idle:0; lastwait:10000]. 12:26:36,411 ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[default-host].[/APP].[AppConf]] (http-/XX.XXX.XXX.X:XXXXX-X) JBWEB000236: Servlet.service() for servlet AppConf threw exception: org.jboss