Hi

I am using jboss connection pool mechanism.......following is my

oracle-mobile-ds.xml...I am using jboss3.25,jdk1.4.1 and eclipse on

windowsxp....Do u have any idea????

 

- <datasources>

- <local-tx-datasource>

<jndi-name>jdbc/ora_mobile_ds</jndi-name>

<connection-url>jdbc:oracle:thin:@123.456.789.123:1521:TEST</connection-url>

<driver-class>oracle.jdbc.driver.OracleDriver</driver-class>

<user-name>shanta</user-name>

<password>shanta</password>

<min-pool-size>5</min-pool-size>

<max-pool-size>20</max-pool-size>

<prepared-statement-cache-size>50</prepared-statement-cache-size>

</local-tx-datasource>

</datasources>

 

i have added following entry in standardjaws.xml

<datasource>java:/jdbc/ora_mobile_ds</datasource>

<type-mapping>Oracle9</type-mapping>

<debug>true</debug>

 

 

I am using this one in my programm and i am closing

connection explictly in my programm.I have observed some misbehaviour. Its

not able to close the connection ,even though i have explicitly closed

connection.

I am not getting any idea....why its not

closing connection even after i explicitly close the connection

 

public static void close(ResultSet rs)

{

try {

if (rs != null) rs.close();

}

catch (SQLException sqle)

{

sqle.printStackTrace();

}

}

public static void close(CallableStatement stmt)

{

try {

if (stmt != null) stmt.close();

}

catch (SQLException sqle)

{

sqle.printStackTrace();

}

}

public static void close(Statement stmt)

{

try {

if (stmt != null) stmt.close();

}

catch (SQLException sqle)

{

sqle.printStackTrace();

}

}

public static void close(PreparedStatement stmt)

{

try {

if (stmt != null) stmt.close();

}

catch (SQLException sqle)

{

sqle.printStackTrace();

}

}

public static void close(Connection conn)

{

try {

if (conn != null) conn.close();

}

catch (SQLException sqle)

{

sqle.printStackTrace();

}

}


Do you Yahoo!?
Y! Messenger - Communicate in real time. Download now.

Reply via email to