Oracle’s very own database connection proxy, CMAN-TDM, brings in per-PDB pooling capabilities in 23ai

Sharad Chandran
Oracle Developers
Published in
2 min readFeb 15, 2024
Photo by Vinu T on Unsplash

Oracle Connection Manager (CMAN) is a multi-purpose database connection proxy server used in Oracle deployments. CMAN is available as part of the Oracle Database Enterprise Edition (EE) client package.

CMAN in Traffic Director Mode (TDM), or CMAN-TDM, brings in intelligence to manage incoming client connections through session multiplexing and dynamic load balancing that can optimize the usage of database resources.

Session multiplexing can be handled efficiently through the Proxy Resident Connection Pooling (PRCP) feature in CMAN-TDM. When PRCP is enabled on CMAN-TDM, connection pool(s) are created on the CMAN-TDM server that enable mid-tier clients to share connections to the database.

Oracle Database 21c and beyond supports the multi-tenant architecture model with multiple Pluggable Databases (PDBs) and a single Container Database (CDB). Until recently, PRCP pools can be created for each database service. So if a PDB database instance has multiple services, then a PRCP pool is created for each of the services.

Starting from Oracle EE 23ai version, CMAN-TDM provides a per-PDB PRCP option as well. With this feature, a PRCP pool will be created at the PDB level. This per-PDB PRCP pool will be shared across multiple services associated with the same PDB.

Sample per-PDB PRCP architecture

To enable per-PDB PRCP, the user has to set the PRCP connection factor (TDM_PERPDB_PRCP_CONNFACTOR) parameter to a non-zero positive value in cman.ora (The configuration file for CMAN).

The per-PDB PRCP feature dynamically configures the PRCP pool, by adjusting the maximum size based on the Oracle Compute Unit (OCPU) — an internal parameter — and the PRCP connection factor parameter at the PDB level. CMAN-TDM periodically checks the OCPU value of each PDB and reconfigures the per-PDB PRCP pool size, if required.
The user can further tune the pool sizing by tweaking the PRCP connection factor to a higher or lower value.

You can also view the per-PDB PRCP performance statistics by setting another cman.ora parameter TDM_STATS_FREQUENCYto a non-zero positive value. This will add the statistics in the newly created V$TDM_STATS dynamic view.

In essence, consolidation of PRCP pools per PDB minimizes the fragmentation of session pools across multiple services and automatically applies the sizing for session pools for the whole PDB in an effective manner, leading to better resource management on CMAN-TDM.

What’s more! you can monitor the connection performance with the per-PDB PRCP statistics available in dynamic views as well! Pretty cool!

--

--

Sharad Chandran
Oracle Developers

Sharad Chandran is a Principal Product Manager at Oracle working on building client-side interfaces & APIs for the Oracle DB in C/C++, Python, Node.js, Go etc.