Search in sources :

Example 1 with BpmPlatformXml

use of org.camunda.bpm.container.impl.metadata.spi.BpmPlatformXml in project camunda-bpm-platform by camunda.

the class StartJcaExecutorServiceStep method performOperationStep.

public void performOperationStep(DeploymentOperation operationContext) {
    BpmPlatformXml bpmPlatformXml = operationContext.getAttachment(Attachments.BPM_PLATFORM_XML);
    checkConfiguration(bpmPlatformXml.getJobExecutor());
    final PlatformServiceContainer serviceContainer = operationContext.getServiceContainer();
    serviceContainer.startService(ServiceTypes.BPM_PLATFORM, RuntimeContainerDelegateImpl.SERVICE_NAME_EXECUTOR, new JcaExecutorServiceDelegate(executorService));
}
Also used : PlatformServiceContainer(org.camunda.bpm.container.impl.spi.PlatformServiceContainer) BpmPlatformXml(org.camunda.bpm.container.impl.metadata.spi.BpmPlatformXml)

Example 2 with BpmPlatformXml

use of org.camunda.bpm.container.impl.metadata.spi.BpmPlatformXml in project camunda-bpm-platform by camunda.

the class StartManagedThreadPoolStep method getJobExecutorXml.

private JobExecutorXml getJobExecutorXml(DeploymentOperation operationContext) {
    BpmPlatformXml bpmPlatformXml = operationContext.getAttachment(Attachments.BPM_PLATFORM_XML);
    JobExecutorXml jobExecutorXml = bpmPlatformXml.getJobExecutor();
    return jobExecutorXml;
}
Also used : BpmPlatformXml(org.camunda.bpm.container.impl.metadata.spi.BpmPlatformXml) JobExecutorXml(org.camunda.bpm.container.impl.metadata.spi.JobExecutorXml)

Example 3 with BpmPlatformXml

use of org.camunda.bpm.container.impl.metadata.spi.BpmPlatformXml in project camunda-bpm-platform by camunda.

the class StartJobExecutorStep method getJobExecutorXml.

private JobExecutorXml getJobExecutorXml(DeploymentOperation operationContext) {
    BpmPlatformXml bpmPlatformXml = operationContext.getAttachment(Attachments.BPM_PLATFORM_XML);
    JobExecutorXml jobExecutorXml = bpmPlatformXml.getJobExecutor();
    return jobExecutorXml;
}
Also used : BpmPlatformXml(org.camunda.bpm.container.impl.metadata.spi.BpmPlatformXml) JobExecutorXml(org.camunda.bpm.container.impl.metadata.spi.JobExecutorXml)

Example 4 with BpmPlatformXml

use of org.camunda.bpm.container.impl.metadata.spi.BpmPlatformXml in project camunda-bpm-platform by camunda.

the class AbstractParseBpmPlatformXmlStep method performOperationStep.

public void performOperationStep(DeploymentOperation operationContext) {
    URL bpmPlatformXmlSource = getBpmPlatformXmlStream(operationContext);
    ensureNotNull("Unable to find bpm-platform.xml. This file is necessary for deploying the camunda BPM platform", "bpmPlatformXmlSource", bpmPlatformXmlSource);
    // parse the bpm platform xml
    BpmPlatformXml bpmPlatformXml = new BpmPlatformXmlParser().createParse().sourceUrl(bpmPlatformXmlSource).execute().getBpmPlatformXml();
    // attach to operation context
    operationContext.addAttachment(Attachments.BPM_PLATFORM_XML, bpmPlatformXml);
}
Also used : BpmPlatformXmlParser(org.camunda.bpm.container.impl.metadata.BpmPlatformXmlParser) BpmPlatformXml(org.camunda.bpm.container.impl.metadata.spi.BpmPlatformXml) URL(java.net.URL)

Example 5 with BpmPlatformXml

use of org.camunda.bpm.container.impl.metadata.spi.BpmPlatformXml in project camunda-bpm-platform by camunda.

the class BpmPlatformXmlParserTest method testParseBpmPlatformXmlNoEngine.

public void testParseBpmPlatformXmlNoEngine() {
    BpmPlatformXml bpmPlatformXml = parser.createParse().sourceUrl(getStreamUrl("bpmplatform_xml_no_engine.xml")).execute().getBpmPlatformXml();
    assertNotNull(bpmPlatformXml);
    assertNotNull(bpmPlatformXml.getJobExecutor());
    assertEquals(0, bpmPlatformXml.getProcessEngines().size());
    JobExecutorXml jobExecutorXml = bpmPlatformXml.getJobExecutor();
    assertEquals(1, jobExecutorXml.getJobAcquisitions().size());
    JobAcquisitionXml jobAcquisitionXml = jobExecutorXml.getJobAcquisitions().get(0);
    assertEquals("default", jobAcquisitionXml.getName());
    assertEquals("org.camunda.bpm.engine.impl.jobexecutor.DefaultJobExecutor", jobAcquisitionXml.getJobExecutorClassName());
    assertEquals(2, jobAcquisitionXml.getProperties().size());
}
Also used : BpmPlatformXml(org.camunda.bpm.container.impl.metadata.spi.BpmPlatformXml) JobExecutorXml(org.camunda.bpm.container.impl.metadata.spi.JobExecutorXml) JobAcquisitionXml(org.camunda.bpm.container.impl.metadata.spi.JobAcquisitionXml)

Aggregations

BpmPlatformXml (org.camunda.bpm.container.impl.metadata.spi.BpmPlatformXml)9 JobExecutorXml (org.camunda.bpm.container.impl.metadata.spi.JobExecutorXml)4 ProcessEnginePluginXml (org.camunda.bpm.container.impl.metadata.spi.ProcessEnginePluginXml)4 ProcessEngineXml (org.camunda.bpm.container.impl.metadata.spi.ProcessEngineXml)4 JobAcquisitionXml (org.camunda.bpm.container.impl.metadata.spi.JobAcquisitionXml)2 URL (java.net.URL)1 BpmPlatformXmlParser (org.camunda.bpm.container.impl.metadata.BpmPlatformXmlParser)1 PlatformServiceContainer (org.camunda.bpm.container.impl.spi.PlatformServiceContainer)1