Package com.sun.enterprise.config

Examples of com.sun.enterprise.config.ConfigContext


        if (_instance != null)
           return _instance;
        else {
            _instance = new GMSStartEvent(proxy);
            String currentServer = ApplicationServer.getServerContext().getInstanceName();
            ConfigContext context  =  AdminService.getAdminService().getAdminContext().getAdminConfigContext();
            if(AdminService.getAdminService().isDas()) {
                try {
                    Cluster[] clusters = (Cluster[]) ClusterHelper.getClustersInDomain(context);
                    for (int i = 0; i < clusters.length; i++) {
                        String clusterName = clusters[i].getName();
View Full Code Here


            }
        } catch (Exception ex) { }
    }

    private void doFunction() {
        ConfigContext ctx = ApplicationServer.getServerContext().getConfigContext();
        Domain svr = null;
        try {
            svr = ServerBeansFactory.getDomainBean(ctx);
        } catch(ConfigException ex) { }
        String logsDir = svr.getLogRoot();
View Full Code Here

    */
    public synchronized void setThresholdWait(long value) {
        try {
            long lbTimeout = 0;
           
            ConfigContext cfgCtx = ApplicationServer.getServerContext().getConfigContext();
            Set<LbConfig> lbs = ServerBeansFactory.getLbConfigs(cfgCtx);
            LbConfig selectLb = null;
            for ( LbConfig lb : lbs) {
                if (lb.getClusterRefByRef(clusterName)!= null) {
                    selectLb = lb;
View Full Code Here

    }
   
    boolean checkMonitoringEnabled() throws ConfigException {
        ServerContext srCtx = ApplicationServer.getServerContext();
        ConfigContext cfgCtx = srCtx.getConfigContext();
        Config instanceCfg = ServerBeansFactory.getConfigBean(cfgCtx);
       
        MonitoringLevel monitoringLevel = MonitoringLevel.OFF;

        if (instanceCfg.getMonitoringService() != null) {
View Full Code Here

                         + localStrings.getString("threadhang.potentialcount",
                                                 potentialCount);
        if (alertRef != null) {
            try {
                ServerContext srCtx = ApplicationServer.getServerContext();
                ConfigContext cfgCtx = srCtx.getConfigContext();
       
                Domain domain = ServerBeansFactory.getDomainBean(cfgCtx);
                Applications apps = domain.getApplications();
                Mbean definedMBean = apps.getMbeanByName(alertRef);
                ObjectName objName =
View Full Code Here

        Boolean isHealthy = false;
        try {
            ArrayList<HttpListener> enabledListeners = new ArrayList<HttpListener>();
         
            Server serv = instance.getServer();
            ConfigContext cfgCtx = InstanceHangAction.configCtx;
            Config cfg = ServerHelper.getConfigForServer(cfgCtx, serv.getName());
       
            // get http-listeners on this server
            HttpService httpSrv = cfg.getHttpService();
            HttpListener[] listeners = httpSrv.getHttpListener();
View Full Code Here

        }
    }
   
    private void handleClusterNotification(javax.management.Notification notification, Object handback) {
        // for every pool which is self managed, see if it effects the max pool size
        ConfigContext ctx = AdminService.getAdminService().getAdminContext().getAdminConfigContext();
        String poolName = null;
        Iterator<String> iter = (Iterator<String>)createdPools.keys();
        while (iter.hasNext()){
            poolName = iter.next();
            try {
View Full Code Here

        }
    }
   
    private int calcMaxPoolSize(String poolName) {
        int maxConnections = poolNameMap.get(poolName);
        ConfigContext ctx = AdminService.getAdminService().getAdminContext().getAdminConfigContext();
        Server servers[] = null;
        try {
            servers = ServerHelper.getServersReferencingJdbcPool(ctx, poolName);
        } catch (ConfigException ex) {
            // log the exception
View Full Code Here

        super(target,repositoryDir,local);
    }
   
   
    public boolean validateTarget() throws DiagnosticException {
        ConfigContext configContext = getServerContext().getConfigContext();
        try {
            String domainName = ServerHelper.getAdministrativeDomainName(
                    configContext,null);
           
            if(domainName != null)
View Full Code Here

    }

    public void recoverXAResources(boolean force) {
        if (force) {
            try {
                ConfigContext ctx =
                        ApplicationServer.getServerContext().getConfigContext();
                TransactionService txnService = null;
                txnService =
                        ServerBeansFactory.getTransactionServiceBean(ctx);
                PluggableFeatureFactory pff = ApplicationServer.getServerContext().
View Full Code Here

TOP

Related Classes of com.sun.enterprise.config.ConfigContext

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.