public void deploy(DeploymentInfo unit) throws DeploymentException { if (ignoreDeployment(unit)) return; if (isWebServiceDeployment(unit)) { log.debug("deploy: " + unit.shortName); Deployment dep = getDeployment(unit); if (dep == null) { dep = createDeployment(unit); dep.addAttachment(DeploymentInfo.class, unit); } getRuntime().create(dep); unit.context.put(Deployment.class, dep); } }
/** Get the Deployment for a given DeploymentInfo */ public Deployment getDeployment(DeploymentInfo unit) { Deployment dep = (Deployment)unit.context.get(Deployment.class); return (dep != null && dep.getType() == getDeploymentType() ? dep : null); }
public void deploy(DeploymentInfo unit) throws DeploymentException { if (ignoreDeployment(unit)) return; if (isWebServiceDeployment(unit)) { log.debug("deploy: " + unit.shortName); Deployment dep = getDeployment(unit); if (dep == null) { dep = createDeployment(unit); dep.addAttachment(DeploymentInfo.class, unit); } getDeploymentAspectManager().deploy(dep); unit.context.put(Deployment.class, dep); } }
public void undeploy(DeploymentInfo unit) { if (ignoreDeployment(unit)) return; Deployment dep = getDeployment(unit); if (dep != null) { log.debug("undeploy: " + unit.shortName); getDeploymentAspectManager().undeploy(dep); } }
public void undeploy(DeploymentInfo unit) { if (ignoreDeployment(unit)) return; Deployment dep = getDeployment(unit); if (dep != null) { log.debug("undeploy: " + unit.shortName); getRuntime().stop(dep); getRuntime().destroy(dep); } }
/** Unmrashall the webservices.xml if there is one */ protected WebservicesMetaData getWebservicesMetaData(DeploymentInfo unit, String wsFile) { WebservicesMetaData wsMetaData = (WebservicesMetaData)unit.context.get(WebservicesMetaData.class); UnifiedVirtualFile vfWebservices = getWebservicesFile(unit, wsFile); if (wsMetaData == null && vfWebservices != null) { try { URL wsURL = vfWebservices.toURL(); Element root = DOMUtils.parse(wsURL.openStream()); String namespaceURI = root.getNamespaceURI(); if (namespaceURI.equals("http://java.sun.com/xml/ns/j2ee")) { Unmarshaller unmarshaller = UnmarshallerFactory.newInstance().newUnmarshaller(); ObjectModelFactory factory = new WebservicesFactory(wsURL); wsMetaData = (WebservicesMetaData)unmarshaller.unmarshal(wsURL.openStream(), factory, null); unit.context.put(WebservicesMetaData.class, wsMetaData); } } catch (Exception ex) { throw new WSFDeploymentException(ex); } } return wsMetaData; }
public void deploy(DeploymentInfo unit) throws DeploymentException { if (!ignoreDeployment(unit) && isWebServiceDeployment(unit)) { super.deploy(unit); // Calls create log.debug("deploy: " + unit.shortName); Deployment dep = getDeployment(unit); if (dep == null || (dep.getState() != Deployment.DeploymentState.CREATED) ) throw new DeploymentException("Create step failed"); getRuntime().start(dep); unit.context.put(Deployment.class, dep); } } }
public void undeploy(DeploymentInfo unit) { if (ignoreDeployment(unit)) return; Deployment dep = getDeployment(unit); if (dep != null) { log.debug("undeploy: " + unit.shortName); getRuntime().stop(dep); getRuntime().destroy(dep); } }
/** Unmrashall the webservices.xml if there is one */ protected WebservicesMetaData getWebservicesMetaData(DeploymentInfo unit, String wsFile) { WebservicesMetaData wsMetaData = (WebservicesMetaData)unit.context.get(WebservicesMetaData.class); UnifiedVirtualFile vfWebservices = getWebservicesFile(unit, wsFile); if (wsMetaData == null && vfWebservices != null) { try { URL wsURL = vfWebservices.toURL(); Element root = DOMUtils.parse(wsURL.openStream()); String namespaceURI = root.getNamespaceURI(); if (namespaceURI.equals("http://java.sun.com/xml/ns/j2ee")) { Unmarshaller unmarshaller = UnmarshallerFactory.newInstance().newUnmarshaller(); ObjectModelFactory factory = new WebservicesFactory(wsURL); wsMetaData = (WebservicesMetaData)unmarshaller.unmarshal(wsURL.openStream(), factory, null); unit.context.put(WebservicesMetaData.class, wsMetaData); } } catch (Exception ex) { throw new WSFDeploymentException(ex); } } return wsMetaData; }
public void deploy(DeploymentInfo unit) throws DeploymentException { if (!ignoreDeployment(unit) && isWebServiceDeployment(unit)) { super.deploy(unit); // Calls create log.debug("deploy: " + unit.shortName); Deployment dep = getDeployment(unit); if (dep == null || (dep.getState() != Deployment.DeploymentState.CREATED) ) throw new DeploymentException("Create step failed"); getRuntime().start(dep); unit.context.put(Deployment.class, dep); } } }
public void deploy(DeploymentInfo unit) throws DeploymentException { if (ignoreDeployment(unit)) return; if (isWebServiceDeployment(unit)) { log.debug("deploy: " + unit.shortName); Deployment dep = getDeployment(unit); if (dep == null) { dep = createDeployment(unit); dep.addAttachment(DeploymentInfo.class, unit); } getRuntime().create(dep); unit.context.put(Deployment.class, dep); } }
/** Get the Deployment for a given DeploymentInfo */ public Deployment getDeployment(DeploymentInfo unit) { Deployment dep = (Deployment)unit.context.get(Deployment.class); return (dep != null && dep.getType() == getDeploymentType() ? dep : null); }
/** Unmrashall the webservices.xml if there is one */ protected WebservicesMetaData getWebservicesMetaData(DeploymentInfo unit, String wsFile) { WebservicesMetaData wsMetaData = (WebservicesMetaData)unit.context.get(WebservicesMetaData.class); UnifiedVirtualFile vfWebservices = getWebservicesFile(unit, wsFile); if (wsMetaData == null && vfWebservices != null) { try { URL wsURL = vfWebservices.toURL(); Element root = DOMUtils.parse(wsURL.openStream()); String namespaceURI = root.getNamespaceURI(); if (namespaceURI.equals("http://java.sun.com/xml/ns/j2ee")) { Unmarshaller unmarshaller = UnmarshallerFactory.newInstance().newUnmarshaller(); ObjectModelFactory factory = new WebservicesFactory(wsURL); wsMetaData = (WebservicesMetaData)unmarshaller.unmarshal(wsURL.openStream(), factory, null); unit.context.put(WebservicesMetaData.class, wsMetaData); } } catch (Exception ex) { throw new WSFDeploymentException(ex); } } return wsMetaData; }
/** Get the Deployment for a given DeploymentInfo */ public Deployment getDeployment(DeploymentInfo unit) { Deployment dep = (Deployment)unit.context.get(Deployment.class); return (dep != null && dep.getType() == getDeploymentType() ? dep : null); }