nrg4878 commented on code in PR #3773:
URL: https://github.com/apache/hive/pull/3773#discussion_r1026978386
##########
standalone-metastore/metastore-server/src/main/java/org/apache/hadoop/hive/metastore/PersistenceManagerProvider.java:
##########
@@ -251,11 +277,14 @@ private static PersistenceManagerFactory
initPMF(Configuration conf, boolean for
if (dsp == null) {
pmf = JDOHelper.getPersistenceManagerFactory(dsProp);
} else {
- try {
+ String sourceName = forCompactor ? "objectstore-compactor" :
"objectstore";
+ try (DataSourceProvider.DataSourceNameConfigurator configurator =
+ new DataSourceProvider.DataSourceNameConfigurator(conf,
sourceName)) {
Review Comment:
so the name of the pool will be output to the metrics file as well?
##########
standalone-metastore/metastore-server/src/main/java/org/apache/hadoop/hive/metastore/txn/TxnHandler.java:
##########
@@ -369,11 +369,15 @@ public void setConf(Configuration conf){
int maxPoolSize = MetastoreConf.getIntVar(conf,
ConfVars.CONNECTION_POOLING_MAX_CONNECTIONS);
synchronized (TxnHandler.class) {
- if (connPool == null) {
- connPool = setupJdbcConnectionPool(conf, maxPoolSize);
- }
- if (connPoolMutex == null) {
- connPoolMutex = setupJdbcConnectionPool(conf, maxPoolSize);
+ try (DataSourceProvider.DataSourceNameConfigurator configurator =
+ new DataSourceProvider.DataSourceNameConfigurator(conf, "txn"))
{
Review Comment:
nit: should we call this txnhandler instead of txn?
##########
standalone-metastore/metastore-server/src/main/java/org/apache/hadoop/hive/metastore/PersistenceManagerProvider.java:
##########
@@ -251,11 +277,14 @@ private static PersistenceManagerFactory
initPMF(Configuration conf, boolean for
if (dsp == null) {
pmf = JDOHelper.getPersistenceManagerFactory(dsProp);
} else {
- try {
+ String sourceName = forCompactor ? "objectstore-compactor" :
"objectstore";
Review Comment:
will the pool name be as it is here or will it be something like
objectstore-compactor-pool or objectstore-pool?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]