Can you give your java code which create the pool and the jdbc connections?
Then, I will try to give you the java code to monitor the jdbc info and
the sql requests.
bye,
Emeric
Le 02/11/2011 10:59, kk a �crit :
Given that you use the DriverManager.getConnection directly to get a
jdbc connection as said below, the following should work to monitor the
jdbc connections and the sql requests:
Class.forName("net.bull.javamelody.JdbcDriver");
java.util.Properties info = new java.util.Properties();
info.put("driver", "com.mysql.jdbc.Driver");
info.put("user", user);
info.put("password", password);
Connection conn = DriverManager.getConnection(connectionString, info);
where connectionString is for example
"jdbc:mysql://localhost/db?allowMultiQueries=true"
bye,
Emeric
Le 03/11/2011 09:53, kk a �crit :
> Here we go. The connection is created like this
>
> if (ConnectionString == null || ConnectionString.length() == 0) {
> throw new SQLException("Connection string for '" +
> ConnectionName + "' is not configured.");
> }
>
> Connection conn =
> DriverManager.getConnection(ConnectionString);
> return new DbConnection(conn, this);
>
> The connection is created only when there are no connection object in
> the pool. Pool is implemented using arraylist. If the array lIst do
> not have any free connection, then a new connection is created.
>
> Regards
> KK