Package com.sun.appserv.management.config

Examples of com.sun.appserv.management.config.ThreadPoolConfig


    }
   
      public static ThreadPoolConfig
  ensureDefaultInstance( final ConfigConfig cc )
  {
      ThreadPoolConfig result = cc.getThreadPoolConfigMap().get( getDefaultInstanceName() );
     
      if ( result == null )
      {
          result  = createInstance( cc, getDefaultInstanceName(), OPTIONAL);
      }
View Full Code Here


        boolean hasOrig = (selectedList == null || selectedList.size()==0) ? false: true;
      
        List result = new ArrayList();
        if (iter != null){
            while(iter.hasNext()){
                ThreadPoolConfig threadConfig = (ThreadPoolConfig) iter.next();
                HashMap oneRow = new HashMap();
                String name = threadConfig.getThreadPoolId();
                oneRow.put("name", name);
                oneRow.put("selected", (hasOrig)? ConnectorsHandlers.isSelected(name, selectedList): false);
                String maxSize = threadConfig.getMaxThreadPoolSize();
                String minSize = threadConfig.getMinThreadPoolSize();
                oneRow.put("maxSize", (maxSize == null) ? " ": maxSize);
                oneRow.put("minSize", (minSize == null) ? " ": minSize);
                result.add(oneRow);
            }
        }
View Full Code Here

            getDefaultThreadPoolValues(handlerCtx);
            return;
        }
        String threadPoolId = (String)handlerCtx.getInputValue("ThreadPoolId");
        Map threadPoolsMap = config.getThreadPoolConfigMap();
        ThreadPoolConfig threadConfig = (ThreadPoolConfig)threadPoolsMap.get(threadPoolId);
        String minPoolSize = threadConfig.getMinThreadPoolSize();
        String maxPoolSize = threadConfig.getMaxThreadPoolSize();
        String idleTimeout = threadConfig.getIdleThreadTimeoutInSeconds();
        String noWorkQ = threadConfig.getNumWorkQueues();
       
        handlerCtx.setOutputValue("MinPoolSize", minPoolSize);
        handlerCtx.setOutputValue("MaxPoolSize", maxPoolSize);
        handlerCtx.setOutputValue("IdleTimeout", idleTimeout);
        handlerCtx.setOutputValue("NoWorkQ", noWorkQ);
View Full Code Here

        public static void saveThreadPoolValues(HandlerContext handlerCtx) {
        String configName = (String) handlerCtx.getInputValue("ConfigName");
        ConfigConfig config = AMXUtil.getConfig(configName);
        String threadPoolId = (String)handlerCtx.getInputValue("ThreadPoolId");
        try{
            ThreadPoolConfig threadConfig = null;
            Boolean edit = (Boolean) handlerCtx.getInputValue("Edit");
            if(!edit){
                threadConfig = config.createThreadPoolConfig(threadPoolId, new HashMap());
            } else {
                Map threadPoolsMap = config.getThreadPoolConfigMap();
                threadConfig = (ThreadPoolConfig)threadPoolsMap.get(threadPoolId);
            }
            threadConfig.setMinThreadPoolSize((String)handlerCtx.getInputValue("MinPoolSize"));
            threadConfig.setMaxThreadPoolSize((String)handlerCtx.getInputValue("MaxPoolSize"));
            threadConfig.setIdleThreadTimeoutInSeconds((String)handlerCtx.getInputValue("IdleTimeout"));
            threadConfig.setNumWorkQueues((String)handlerCtx.getInputValue("NoWorkQ"));
        }catch (Exception ex){
            GuiUtil.handleException(handlerCtx, ex);
        }
    }
View Full Code Here

TOP

Related Classes of com.sun.appserv.management.config.ThreadPoolConfig

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.