private void unregisterManagementNodes() { QName applicationName = _deployment.getName(); if (applicationName == null) { return; } _deployUnit.createDeploymentSubModel(SwitchYardExtension.SUBSYSTEM_NAME, PathElement.pathElement(SwitchYardModelConstants.APPLICATION, applicationName.toString())).clear(); }
private void unregisterManagementNodes() { QName applicationName = _deployment.getName(); if (applicationName == null) { return; } _deployUnit.createDeploymentSubModel(SwitchYardExtension.SUBSYSTEM_NAME, PathElement.pathElement(SwitchYardModelConstants.APPLICATION, applicationName.toString())).clear(); }
@Override public void start(final Deployment dep) { final DeploymentUnit unit = dep.getAttachment(DeploymentUnit.class); if (unit instanceof WSEndpointDeploymentUnit) return; for (final Endpoint endpoint : dep.getService().getEndpoints()) { ModelNode op = null; try { op = unit.createDeploymentSubModel(WSExtension.SUBSYSTEM_NAME, PathElement.pathElement(ENDPOINT, URLEncoder.encode(getId(endpoint), "UTF-8"))); } catch (final UnsupportedEncodingException e) { throw new RuntimeException(e); } op.get(ENDPOINT_NAME).set(getName(endpoint)); op.get(ENDPOINT_CONTEXT).set(getContext(endpoint)); op.get(ENDPOINT_CLASS).set(endpoint.getTargetBeanName()); op.get(ENDPOINT_TYPE).set(endpoint.getType().toString()); op.get(ENDPOINT_WSDL).set(endpoint.getAddress() + "?wsdl"); } }
private void installManagementModel(final XaDataSource ds, final DeploymentUnit deploymentUnit, final PathAddress addr) { XMLXaDataSourceRuntimeHandler.INSTANCE.registerDataSource(addr, ds); deploymentUnit.createDeploymentSubModel(DataSourcesExtension.SUBSYSTEM_NAME, addr.getLastElement()); if (ds.getXaDataSourceProperty() != null) { for (final Map.Entry<String, String> prop : ds.getXaDataSourceProperty().entrySet()) { PathAddress registration = PathAddress.pathAddress(addr.getLastElement(), PathElement.pathElement(XA_CONNECTION_PROPERTIES, prop.getKey())); createDeploymentSubModel(registration, deploymentUnit); } } }
private void installManagementModel(final DataSource ds, final DeploymentUnit deploymentUnit, final PathAddress addr) { XMLDataSourceRuntimeHandler.INSTANCE.registerDataSource(addr, ds); deploymentUnit.createDeploymentSubModel(DataSourcesExtension.SUBSYSTEM_NAME, addr.getLastElement()); if (ds.getConnectionProperties() != null) { for (final Map.Entry<String, String> prop : ds.getConnectionProperties().entrySet()) { PathAddress registration = PathAddress.pathAddress(addr.getLastElement(), PathElement.pathElement(CONNECTION_PROPERTIES, prop.getKey())); createDeploymentSubModel(registration, deploymentUnit); } } }
private void registerManagementNodes() { QName applicationName = _deployment.getName(); if (applicationName == null) { return; } ServiceController<?> adminService = _deployUnit.getServiceRegistry().getService( SwitchYardAdminService.SERVICE_NAME); if (adminService == null) { return; } BaseSwitchYard switchYard = BaseSwitchYard.class.cast(adminService.getValue()); if (switchYard == null) { return; } ModelNode deployNode = _deployUnit.createDeploymentSubModel(SwitchYardExtension.SUBSYSTEM_NAME, PathElement.pathElement(SwitchYardModelConstants.APPLICATION, applicationName.toString())); Application application = switchYard.getApplication(applicationName); if (application == null) { return; } deployNode.set(ModelNodeCreationUtil.createApplicationNode(application)); }
private void registerManagementNodes() { QName applicationName = _deployment.getName(); if (applicationName == null) { return; } ServiceController<?> adminService = _deployUnit.getServiceRegistry().getService( SwitchYardAdminService.SERVICE_NAME); if (adminService == null) { return; } BaseSwitchYard switchYard = BaseSwitchYard.class.cast(adminService.getValue()); if (switchYard == null) { return; } ModelNode deployNode = _deployUnit.createDeploymentSubModel(SwitchYardExtension.SUBSYSTEM_NAME, PathElement.pathElement(SwitchYardModelConstants.APPLICATION, applicationName.toString())); Application application = switchYard.getApplication(applicationName); if (application == null) { return; } deployNode.set(ModelNodeCreationUtil.createApplicationNode(application)); }
private void installManagementResource(ComponentConfiguration configuration, DeploymentUnit deploymentUnit) { final EJBComponentType type = EJBComponentType.getComponentType(configuration); PathAddress addr = getComponentAddress(type, configuration, deploymentUnit); final AbstractEJBComponentRuntimeHandler handler = type.getRuntimeHandler(); handler.registerComponent(addr, configuration.getComponentDescription().getStartServiceName()); deploymentUnit.addToAttachmentList(EjbDeploymentAttachmentKeys.MANAGED_COMPONENTS, new InstalledComponent(type, addr)); deploymentUnit.createDeploymentSubModel(EJB3Extension.SUBSYSTEM_NAME, addr.getLastElement()); }