public class org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO extends java.lang.Object
{
private final org.eclipse.collections.api.map.ConcurrentMutableMap pools;
private final java.util.Set dataSourceSpecifications;
public void <init>(org.eclipse.collections.api.map.ConcurrentMutableMap)
{
org.eclipse.collections.api.map.ConcurrentMutableMap v;
java.util.Set v;
org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO v;
v := @this: org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO;
v := @parameter: org.eclipse.collections.api.map.ConcurrentMutableMap;
specialinvoke v.<java.lang.Object: void <init>()>();
v.<org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO: org.eclipse.collections.api.map.ConcurrentMutableMap pools> = v;
v = specialinvoke v.<org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO: java.util.Set buildDataSourceSpecifications()>();
v.<org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO: java.util.Set dataSourceSpecifications> = v;
return;
}
private java.util.Set buildDataSourceSpecifications()
{
java.util.HashSet v;
org.eclipse.collections.api.map.ConcurrentMutableMap v;
org.eclipse.collections.api.block.procedure.Procedure v;
org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO v;
v := @this: org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO;
v = new java.util.HashSet;
specialinvoke v.<java.util.HashSet: void <init>()>();
v = v.<org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO: org.eclipse.collections.api.map.ConcurrentMutableMap pools>;
v = staticinvoke <org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO$lambda_buildDataSourceSpecifications_75ffb170_1__28: org.eclipse.collections.api.block.procedure.Procedure bootstrap$(java.util.Set)>(v);
interfaceinvoke v.<org.eclipse.collections.api.map.ConcurrentMutableMap: void forEach(org.eclipse.collections.api.block.procedure.Procedure)>(v);
return v;
}
public int getPoolsSize()
{
org.eclipse.collections.api.map.ConcurrentMutableMap v, v;
int v;
org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO v;
v := @this: org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO;
v = v.<org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO: org.eclipse.collections.api.map.ConcurrentMutableMap pools>;
if v == null goto label;
v = v.<org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO: org.eclipse.collections.api.map.ConcurrentMutableMap pools>;
v = interfaceinvoke v.<org.eclipse.collections.api.map.ConcurrentMutableMap: int size()>();
goto label;
label:
v = 0;
label:
return v;
}
public int getDataSourceSpecificationSize()
{
int v;
java.util.Set v, v;
org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO v;
v := @this: org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO;
v = v.<org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO: java.util.Set dataSourceSpecifications>;
if v == null goto label;
v = v.<org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO: java.util.Set dataSourceSpecifications>;
v = interfaceinvoke v.<java.util.Set: int size()>();
goto label;
label:
v = 0;
label:
return v;
}
public java.util.Set getStores()
{
java.util.stream.Stream v, v;
java.util.Set v;
java.lang.Object v;
java.util.stream.Collector v;
org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO v;
java.util.function.Function v;
v := @this: org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO;
v = v.<org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO: java.util.Set dataSourceSpecifications>;
v = interfaceinvoke v.<java.util.Set: java.util.stream.Stream stream()>();
v = staticinvoke <org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO$lambda_getStores_1__29: java.util.function.Function bootstrap$(org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO)>(v);
v = interfaceinvoke v.<java.util.stream.Stream: java.util.stream.Stream map(java.util.function.Function)>(v);
v = staticinvoke <java.util.stream.Collectors: java.util.stream.Collector toSet()>();
v = interfaceinvoke v.<java.util.stream.Stream: java.lang.Object collect(java.util.stream.Collector)>(v);
return v;
}
public java.util.List getPools()
{
org.eclipse.collections.api.map.ConcurrentMutableMap v;
org.eclipse.collections.api.RichIterable v, v;
org.eclipse.collections.api.block.function.Function v;
org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO v;
org.eclipse.collections.api.list.MutableList v;
v := @this: org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO;
v = v.<org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO: org.eclipse.collections.api.map.ConcurrentMutableMap pools>;
v = interfaceinvoke v.<org.eclipse.collections.api.map.ConcurrentMutableMap: org.eclipse.collections.api.RichIterable valuesView()>();
v = staticinvoke <org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO$lambda_getPools_c12fcad_1__30: org.eclipse.collections.api.block.function.Function bootstrap$()>();
v = interfaceinvoke v.<org.eclipse.collections.api.RichIterable: org.eclipse.collections.api.RichIterable collect(org.eclipse.collections.api.block.function.Function)>(v);
v = interfaceinvoke v.<org.eclipse.collections.api.RichIterable: org.eclipse.collections.api.list.MutableList toList()>();
return v;
}
static org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO$ConnectionPool buildConnectionPool(org.finos.legend.engine.plan.execution.stores.relational.connection.ds.DataSourceWithStatistics)
{
org.finos.legend.engine.plan.execution.stores.relational.connection.ds.DataSourceSpecification v;
org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO$ConnectionPool v;
org.finos.legend.engine.plan.execution.stores.relational.connection.ds.DataSourceWithStatistics v;
org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO$RelationalStoreInfo v;
v := @parameter: org.finos.legend.engine.plan.execution.stores.relational.connection.ds.DataSourceWithStatistics;
v = new org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO$ConnectionPool;
v = new org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO$RelationalStoreInfo;
v = virtualinvoke v.<org.finos.legend.engine.plan.execution.stores.relational.connection.ds.DataSourceWithStatistics: org.finos.legend.engine.plan.execution.stores.relational.connection.ds.DataSourceSpecification getDataSourceSpecification()>();
specialinvoke v.<org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO$RelationalStoreInfo: void <init>(org.finos.legend.engine.plan.execution.stores.relational.connection.ds.DataSourceSpecification)>(v);
specialinvoke v.<org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO$ConnectionPool: void <init>(org.finos.legend.engine.plan.execution.stores.relational.connection.ds.DataSourceWithStatistics,org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO$RelationalStoreInfo)>(v, v);
return v;
}
static org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO$PoolStatic buildPoolStaticConfiguration(com.zaxxer.hikari.HikariDataSource)
{
org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO$PoolStatic v;
long v, v, v, v, v;
java.lang.Long v;
com.zaxxer.hikari.HikariDataSource v;
int v, v;
java.lang.String v, v;
v := @parameter: com.zaxxer.hikari.HikariDataSource;
if v != null goto label;
return null;
label:
v = new org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO$PoolStatic;
v = virtualinvoke v.<com.zaxxer.hikari.HikariDataSource: java.lang.String getJdbcUrl()>();
v = virtualinvoke v.<com.zaxxer.hikari.HikariDataSource: java.lang.String getConnectionInitSql()>();
v = virtualinvoke v.<com.zaxxer.hikari.HikariDataSource: long getConnectionTimeout()>();
v = virtualinvoke v.<com.zaxxer.hikari.HikariDataSource: long getIdleTimeout()>();
v = virtualinvoke v.<com.zaxxer.hikari.HikariDataSource: int getMaximumPoolSize()>();
v = virtualinvoke v.<com.zaxxer.hikari.HikariDataSource: int getMinimumIdle()>();
v = staticinvoke <java.lang.Long: java.lang.Long getLong(java.lang.String,long)>("com.zaxxer.hikari.housekeeping.periodMs", 0L);
v = virtualinvoke v.<java.lang.Long: long longValue()>();
v = virtualinvoke v.<com.zaxxer.hikari.HikariDataSource: long getMaxLifetime()>();
v = virtualinvoke v.<com.zaxxer.hikari.HikariDataSource: long getLeakDetectionThreshold()>();
specialinvoke v.<org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO$PoolStatic: void <init>(java.lang.String,java.lang.String,long,long,long,long,long,long,long)>(v, v, v, v, v, v, v, v, v);
return v;
}
static org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO$PoolDynamic buildPoolDynamicStats(com.zaxxer.hikari.HikariDataSource)
{
org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO$PoolDynamic v;
com.zaxxer.hikari.HikariDataSource v;
int v, v, v, v;
com.zaxxer.hikari.HikariPoolMXBean v;
v := @parameter: com.zaxxer.hikari.HikariDataSource;
if v != null goto label;
return null;
label:
v = virtualinvoke v.<com.zaxxer.hikari.HikariDataSource: com.zaxxer.hikari.HikariPoolMXBean getHikariPoolMXBean()>();
v = new org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO$PoolDynamic;
v = interfaceinvoke v.<com.zaxxer.hikari.HikariPoolMXBean: int getActiveConnections()>();
v = interfaceinvoke v.<com.zaxxer.hikari.HikariPoolMXBean: int getIdleConnections()>();
v = interfaceinvoke v.<com.zaxxer.hikari.HikariPoolMXBean: int getThreadsAwaitingConnection()>();
v = interfaceinvoke v.<com.zaxxer.hikari.HikariPoolMXBean: int getTotalConnections()>();
specialinvoke v.<org.finos.legend.engine.plan.execution.stores.relational.connection.ds.state.ConnectionStateManagerPOJO$PoolDynamic: void <init>(long,long,long,long)>(v, v, v, v);
return v;
}
}