Package org.smartcomps.twister.deployer.exception

Examples of org.smartcomps.twister.deployer.exception.DeploymentException


        log.entering(CLASSNAME, methodName, xmlProcessDescription);
        try {
            deploy(getDocument(xmlProcessDescription), null);
        } catch (Exception e) {
            log.error("Failed to deploy a XML description from an URL.", e);
            throw new DeploymentException("unable to deploy the document", e);
        }
        log.exiting(CLASSNAME, methodName);
    }
View Full Code Here


        log.entering(CLASSNAME, methodName, xmlProcessDescription);
        try {
            deploy(getDocument(xmlProcessDescription.toURL()), null);
        } catch (Exception e) {
            log.error("Failed to deploy a XML description from a File.", e);
            throw new DeploymentException("unable to deploy the document", e);
        }
        log.exiting(CLASSNAME, methodName);
    }
View Full Code Here

            TransactionManager.commitTransaction();
        } catch (TransactionException e) {
            try {
                TransactionManager.rollbackTransaction();
            } catch (TransactionException e1) {
                throw new DeploymentException("Could not rollback transaction.", e);
            }
            throw new DeploymentException(e);
        }

        log.exiting(CLASSNAME, methodName);
    }
View Full Code Here

                String urlLocalMapping = getUrlLocalMapping(nsURI);
                nsURL = getClass().getClassLoader().getResource(urlLocalMapping);
                try {
                    doc = getDocument(nsURL);
                } catch (Exception e) {
                    throw new DeploymentException(e);
                }
            }
        }
        return doc;
    }
View Full Code Here

                if (prop != null) {
                    ProcessFactory.addPropertyAlias(prop, e.valueOf("@messageType"),
                            e.valueOf("@part"), e.valueOf("@query"));
                } else {
                    log.error("A propertyAlias is defined without property : " + propertyName);
                    throw new DeploymentException("a propertyAlias is defined without property : " + propertyName);
                }
            }
            Iterator properties = rootElement.elementIterator("property");
            while (properties.hasNext()) {
                Element e = (Element) properties.next();
                String name = e.valueOf("@name");
                if (addedProperty.containsKey(name) == false) {
                    ProcessFactory.addProperty(tp, name, e.valueOf("@type"));
                }
            }
        } catch (Exception e) {
            throw new DeploymentException(e);
        }
    }
View Full Code Here

                ad.deploy(activityElement, tp);
                log.debug("</" + activityElement.getName() + ">");
            } catch (DeploymentException e) {
                TransactionManager.rollbackTransaction();
                log.error("Transation Rolled Back due to " + e.getMessage());
                throw new DeploymentException(e);
            }
        }
        log.exiting(CLASSNAME, methodName);
    }
View Full Code Here

        TwisterProcess tp = null;
        try {
            tp = ProcessFactory.createProcess(name, targetNamespace);
        } catch (DBSessionException e) {
            TransactionManager.rollbackTransaction();
            throw new DeploymentException(e);
        } catch (CreationException e) {
            TransactionManager.rollbackTransaction();
            throw new DeploymentException(e);
        }
        log.exiting(CLASSNAME, methodName, tp);
        return tp;
    }
View Full Code Here

                log.debug("messageType = " + properties);
                log.debug("</correlationSet>");
                try {
                    ProcessFactory.addCorrelation(tp, name, truncNamespace(properties));
                } catch (Exception e) {
                    throw new DeploymentException(e);
                }
            }
        }
    }
View Full Code Here

            ActivityDeployer ad = ActivityDeployerFactory.getActivityDeployer(activityElement.getName());
            Activity act = ad.deploy(activityElement, pick);
            try {
                ActivityFactory.addMessageEvent(pick, act, partnerLink, portType, operation, variable, correlationList);
            } catch (DBSessionException e) {
                throw new DeploymentException(e);
            }
        }
        for (Iterator i = element.elementIterator("onAlarm"); i.hasNext();) {
            Element onAlarmElt = (Element) i.next();
            String forDurationExpression = onAlarmElt.valueOf("@for");
            String untilDeadlineExpression = onAlarmElt.valueOf("@until");
            String timeExpression = null;
            int expressionType = 0;
            if (forDurationExpression != null) {
                timeExpression = forDurationExpression;
                expressionType = AlarmEvent.DURATION_EXPR;
            } else if (untilDeadlineExpression != null) {
                timeExpression = untilDeadlineExpression;
                expressionType = AlarmEvent.DEADLINE_EXPR;
            }
            Element activityElement = getActivityElement(onAlarmElt);
            ActivityDeployer ad = ActivityDeployerFactory.getActivityDeployer(activityElement.getName());
            Activity act = ad.deploy(activityElement, pick);
            try {
                ActivityFactory.addAlarmEvent(pick, act, timeExpression, expressionType);
            } catch (DBSessionException e) {
                throw new DeploymentException(e);
            }
        }
        processChildren = false;
    }
View Full Code Here

                boolean initiate = initiateAtt != null ? StringUtil.booleanValue(initiateAtt.getValue()) : false;
                CorrelationRef correlationRef = null;
                try {
                    correlationRef = ActivityFactory.createCorrelationRef(set, initiate, CorrelationRef.IN);
                } catch (DBSessionException e) {
                    throw new DeploymentException(e);
                }
                correlationList.add(correlationRef);
            }
        }
        return correlationList;
View Full Code Here

TOP

Related Classes of org.smartcomps.twister.deployer.exception.DeploymentException

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.