Package org.jboss.as.console.client.shared.subsys.jca.model

Examples of org.jboss.as.console.client.shared.subsys.jca.model.WorkmanagerPool


                // save
                new ClickHandler() {
                    @Override
                    public void onClick(ClickEvent event) {
                        WorkmanagerPool pool = form.getUpdatedEntity();
                        pool.setShortRunning(type.getValue().equals("short-running"));

                        FormValidation validation = form.validate();
                        if(validation.hasErrors())
                            return;
View Full Code Here


    private List<WorkmanagerPool> parseThreadPool(List<Property> values, boolean shortRunning) {
        List<WorkmanagerPool> result = new ArrayList<WorkmanagerPool>();

        for(Property value : values)
        {
            WorkmanagerPool pool = poolAdapter.fromDMR(value.getValue());

            pool.setShortRunning(shortRunning);
            result.add(pool);
        }

        return result;
    }
View Full Code Here

        closeDialoge();

        if(null==entity.getShortRunning() || entity.getShortRunning().isEmpty())
        {
            // provide a default short running thread pool config (mandatory)
            WorkmanagerPool pool = factory.WorkmanagerPool().as();
            pool.setShortRunning(true);
            //pool.setName("short-running-pool_" + entity.getName());
            pool.setName(entity.getName());
            pool.setMaxThreads(10);
            pool.setQueueLength(10);

            List<WorkmanagerPool> managers = new ArrayList<WorkmanagerPool>(1);
            managers.add(pool);
            entity.setShortRunning(managers);
        }

        ModelNode operation = new ModelNode();
        operation.get(ADDRESS).setEmptyList();
        operation.get(OP).set(COMPOSITE);

        ModelNode workmanagerOp = managerAdapter.fromEntity(entity);
        workmanagerOp.get(ADDRESS).set(Baseadress.get());
        workmanagerOp.get(ADDRESS).add("subsystem", "jca");
        workmanagerOp.get(ADDRESS).add("workmanager", entity.getName());
        workmanagerOp.get(OP).set(ADD);

        WorkmanagerPool pool = entity.getShortRunning().get(0);
        ModelNode poolOp = poolAdapter.fromEntity(pool);
        poolOp.get(ADDRESS).set(Baseadress.get());
        poolOp.get(ADDRESS).add("subsystem", "jca");
        poolOp.get(ADDRESS).add("workmanager", entity.getName());
        poolOp.get(OP).set(ADD);

        if(pool.isShortRunning())
            poolOp.get(ADDRESS).add("short-running-threads", pool.getName());
        else
            poolOp.get(ADDRESS).add("long-running-threads", pool.getName());


        List<ModelNode> steps = new ArrayList<ModelNode>(2);
        steps.add(workmanagerOp);
        steps.add(poolOp);
View Full Code Here

TOP

Related Classes of org.jboss.as.console.client.shared.subsys.jca.model.WorkmanagerPool

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.