Package org.glassfish.resource.common

Examples of org.glassfish.resource.common.PoolInfo


    public String getDriverProperties() {
        return spec.getDetail(DataSourceSpec.DRIVERPROPERTIES);
    }

    protected PoolInfo getPoolInfo(){
        return new PoolInfo(getPoolName(), getApplicationName(), getModuleName());   
    }
View Full Code Here


    private PoolInfo poolInfo;
    private SQLTraceCache sqlTraceCache;

    public JdbcStatsProvider(String poolName, String appName, String moduleName, int sqlTraceCacheSize,
            long timeToKeepQueries) {
        poolInfo = new PoolInfo(poolName, appName, moduleName);
        if(sqlTraceCacheSize > 0) {
            this.sqlTraceCache = new SQLTraceCache(poolName, appName, moduleName, sqlTraceCacheSize, timeToKeepQueries);
        }
    }
View Full Code Here

    public void statementCacheHitEvent(@ProbeParam("poolName") String poolName,
                                       @ProbeParam("appName") String appName,
                                       @ProbeParam("moduleName") String moduleName
                                       ) {

        PoolInfo poolInfo = new PoolInfo(poolName, appName, moduleName);
        if(this.poolInfo.equals(poolInfo)){
            numStatementCacheHit.increment();
        }
    }
View Full Code Here

    public void statementCacheMissEvent(@ProbeParam("poolName") String poolName,
                                        @ProbeParam("appName") String appName,
                                        @ProbeParam("moduleName") String moduleName
                                        ) {

        PoolInfo poolInfo = new PoolInfo(poolName, appName, moduleName);
        if(this.poolInfo.equals(poolInfo)){
            numStatementCacheMiss.increment();
        }
    }
View Full Code Here

                                   @ProbeParam("poolName") String poolName,
                                   @ProbeParam("appName") String appName,
                                   @ProbeParam("moduleName") String moduleName,
                                   @ProbeParam("sql") String sql) {

        PoolInfo poolInfo = new PoolInfo(poolName, appName, moduleName);
        if(this.poolInfo.equals(poolInfo)){
            if(sqlTraceCache != null) {
                if (sql != null) {
                    SQLTrace cacheObj = new SQLTrace(sql, 1,
                            System.currentTimeMillis());
View Full Code Here

    public void potentialStatementLeakEvent(
                                   @ProbeParam("poolName") String poolName,
                                   @ProbeParam("appName") String appName,
                                   @ProbeParam("moduleName") String moduleName) {

        PoolInfo poolInfo = new PoolInfo(poolName, appName, moduleName);
        if(this.poolInfo.equals(poolInfo)){
            numPotentialStatementLeak.increment();
        }
    }
View Full Code Here

        return false;
    }

    boolean pingConnectionPool(String tmpJMSResource) throws ResourceException
    {
        PoolInfo poolInfo = new PoolInfo(tmpJMSResource);
        return connectorRuntime.pingConnectionPool(poolInfo);
    }
View Full Code Here

     */
    public void execute(AdminCommandContext context) {
        final ActionReport report = context.getActionReport();

        try {
            PoolInfo poolInfo = new PoolInfo(poolName, applicationName, moduleName);
            Set<String> validationTableNames = connectorRuntime.getValidationTableNames(poolInfo);
            Properties extraProperties = new Properties();
            extraProperties.put("validationTableNames", new ArrayList(validationTableNames));
            report.setExtraProperties(extraProperties);
        } catch (Exception e) {
View Full Code Here

        @HandlerInput(name = "poolName", type = String.class, required = true)})
    public static void pingJms(HandlerContext handlerCtx) {
        try {
            String poolName = (String) handlerCtx.getInputValue("poolName");
            ConnectorRuntime connectorRuntime = GuiUtil.getHabitat().getComponent(ConnectorRuntime.class);
            PoolInfo poolInfo = new PoolInfo(poolName);
            connectorRuntime.pingConnectionPool(poolInfo);
            GuiUtil.prepareAlert("success", GuiUtil.getMessage("msg.PingSucceed"), null);
        } catch (Exception ex) {
            GuiUtil.prepareAlert("error", GuiUtil.getMessage("msg.Error"), ex.getMessage());
        }
View Full Code Here

        }

        // do the ping
        try
        {
            PoolInfo poolInfo = new PoolInfo(poolName);
            final boolean pingable = connRuntime.pingConnectionPool(poolInfo);
            result.put(PING_SUCCEEDED_KEY, pingable);
        }
        catch (final ResourceException e)
        {
View Full Code Here

TOP

Related Classes of org.glassfish.resource.common.PoolInfo

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.