Friday, 7 January 2011  JRuby example using Oracle UCP
(Universal Connection Pool)  The Oracle Universal Connection
Pool (UCP) for JDBC is a full-featured connection pool for
managing database connections not only for Oracle but also for
other non Oracle databases. The advantage with using UCP with
Oracle is that UCP JDBC connection pools provide a tight
integration with various Oracle Real Application Clusters (RAC)
Database features . The features include Fast Connection
Failover (FCF), Run-Time Connection Load Balancing, and
Connection Affinity.  In this example below we show how to use
UCP with an Oracle Database from a JRuby client BUT just a
single instance database rather then RAC back end.  Note: We are
using the HR schema for this demo  1. Download ucp.jar and
ojdbc6.jar from the links below.  ojdbc6.jar ( ucp.jar (  2.
Create a pool class as follows in a JRuby script called
"ucppool.rb" in a directory called "lib". Client would then
create an instance of this pool class and use it to retrieve /
retu