Package org.camunda.bpm.container.impl.jboss.config

Examples of org.camunda.bpm.container.impl.jboss.config.ManagedProcessEngineMetadata


  protected void startProcessEngine(ProcessEngineXml processEngineXml, DeploymentPhaseContext phaseContext) {
   
    final ServiceTarget serviceTarget = phaseContext.getServiceTarget();
   
    // transform configuration
    ManagedProcessEngineMetadata configuration = transformConfiguration(processEngineXml);
   
    // validate the configuration
    configuration.validate();
   
    // create service instance
    MscManagedProcessEngineController service = new MscManagedProcessEngineController(configuration);
   
    // get the service name for the process engine
View Full Code Here


  /** transforms the configuration as provided via the {@link ProcessEngineXml}
   * into a {@link ManagedProcessEngineMetadata} */
  @SuppressWarnings({ "unchecked", "rawtypes" })
  protected ManagedProcessEngineMetadata transformConfiguration(ProcessEngineXml processEngineXml) {
    return new ManagedProcessEngineMetadata(
        processEngineXml.getName().equals("default"),
        processEngineXml.getName(),
        processEngineXml.getDatasource(),
        processEngineXml.getProperties().get("history"),
        processEngineXml.getConfigurationClass(),
View Full Code Here

          ServiceVerificationHandler verificationHandler, List<ServiceController<?>> newControllers)
          throws OperationFailedException {

    String engineName = PathAddress.pathAddress(operation.get(ModelDescriptionConstants.ADDRESS)).getLastElement().getValue();

    ManagedProcessEngineMetadata processEngineConfiguration = transformConfiguration(context, engineName, model);

    ServiceController<ProcessEngine> controller = installService(context, verificationHandler, processEngineConfiguration);

    newControllers.add(controller);
  }
View Full Code Here

    serviceBuilder.addListener(verificationHandler);
    return serviceBuilder.install();
  }

  protected ManagedProcessEngineMetadata transformConfiguration(final OperationContext context, String engineName, final ModelNode model) {
    return new ManagedProcessEngineMetadata(
        model.get(DEFAULT).asBoolean(),
        engineName,
        model.get(DATASOURCE).asString(),
        model.get(HISTORY_LEVEL).asString(),
        model.get(CONFIGURATION).asString(),
View Full Code Here

    ServiceController<?> defaultEngineService = container.getService(ServiceNames.forManagedProcessEngine("__default"));

    assertNotNull("process engine controller for engine __default is installed ", defaultEngineService);

    ManagedProcessEngineMetadata metadata = ((MscManagedProcessEngineController) defaultEngineService.getService()).getProcessEngineMetadata();
    Map<String, String> configurationProperties = metadata.getConfigurationProperties();
    assertEquals("default", configurationProperties.get("job-name"));
    assertEquals("default", configurationProperties.get("job-acquisition"));
    assertEquals("default", configurationProperties.get("job-acquisition-name"));

    Map<String, String> foxLegacyProperties = metadata.getFoxLegacyProperties();
    assertTrue(foxLegacyProperties.isEmpty());

    assertNotNull("process engine controller for engine __default is installed ", container.getRequiredService(ServiceNames.forManagedProcessEngine("__default")));
    assertNotNull("process engine controller for engine __test is installed ", container.getRequiredService(ServiceNames.forManagedProcessEngine("__test")));

    // check we have parsed the plugin configurations
    metadata = ((MscManagedProcessEngineController) container.getRequiredService(ServiceNames.forManagedProcessEngine("__test")).getService())
        .getProcessEngineMetadata();
    List<ProcessEnginePluginXml> pluginConfigurations = metadata.getPluginConfigurations();

    ProcessEnginePluginXml processEnginePluginXml = pluginConfigurations.get(0);
    assertEquals("org.camunda.bpm.identity.impl.ldap.plugin.LdapIdentityProviderPlugin", processEnginePluginXml.getPluginClass());
    Map<String, String> processEnginePluginXmlProperties = processEnginePluginXml.getProperties();
    assertEquals("abc", processEnginePluginXmlProperties.get("test"));
View Full Code Here

    ServiceController<?> defaultEngineService = container.getService(ServiceNames.forManagedProcessEngine("__default"));

    assertNotNull("process engine controller for engine __default is installed ", defaultEngineService);

    ManagedProcessEngineMetadata metadata = ((MscManagedProcessEngineController) defaultEngineService.getService()).getProcessEngineMetadata();
    Map<String, String> configurationProperties = metadata.getConfigurationProperties();
    assertEquals("default", configurationProperties.get("job-name"));
    assertEquals("default", configurationProperties.get("job-acquisition"));
    assertEquals("default", configurationProperties.get("job-acquisition-name"));

    Map<String, String> foxLegacyProperties = metadata.getFoxLegacyProperties();
    assertTrue(foxLegacyProperties.isEmpty());

    assertNotNull("process engine controller for engine __test is installed ", container.getService(ServiceNames.forManagedProcessEngine("__test")));
    assertNotNull("process engine controller for engine __emptyPropertiesTag is installed ", container.getService(ServiceNames.forManagedProcessEngine("__emptyPropertiesTag")));
    assertNotNull("process engine controller for engine __noPropertiesTag is installed ", container.getService(ServiceNames.forManagedProcessEngine("__noPropertiesTag")));
View Full Code Here

TOP

Related Classes of org.camunda.bpm.container.impl.jboss.config.ManagedProcessEngineMetadata

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.