Package org.apache.uima.collection.impl.cpm.container.deployer.vinci

Examples of org.apache.uima.collection.impl.cpm.container.deployer.vinci.VinciCasProcessorDeployer


          CpeCasProcessor aCasProcessorConfig, ProcessControllerAdapter aPca)
          throws ResourceConfigurationException {
    String deployMode = aCasProcessorConfig.getDeployment();

    if (Constants.DEPLOYMENT_LOCAL.equals(deployMode)) {
      return new VinciCasProcessorDeployer(aCpeFactory);
    } else if (Constants.DEPLOYMENT_REMOTE.equals(deployMode)) {
      String protocol = getProtocol(aCasProcessorConfig, aCpeFactory.getResourceManager());
      if (protocol == null || protocol.trim().length() == 0) {
        throw new ResourceConfigurationException(CPMUtils.CPM_LOG_RESOURCE_BUNDLE,
                "UIMA_CPM_invalid_service_descriptor__SEVERE", new Object[] {
                    Thread.currentThread().getName(), "<uriSpecifier>", "<protocol>" },
                new Exception(CpmLocalizedMessage.getLocalizedMessage(
                        CPMUtils.CPM_LOG_RESOURCE_BUNDLE,
                        "UIMA_CPM_EXP_invalid_service_descriptor__WARNING", new Object[] {
                            Thread.currentThread().getName(), aCasProcessorConfig.getName() })));
      } else if (Constants.SOCKET_PROTOCOL.equalsIgnoreCase(protocol)) {
        if (aPca == null) {
          throw new ResourceConfigurationException(
                  ResourceInitializationException.CONFIG_SETTING_ABSENT,
                  new Object[] { "ProcessControllerAdapter" });
        }
        return new SocketCasProcessorDeployer(aPca, aCpeFactory);
      } else {
        // Default is still Vinci
        return new VinciCasProcessorDeployer(aCpeFactory);
      }
    } else if (Constants.DEPLOYMENT_INTEGRATED.equals(deployMode)) {
      return new CPEDeployerDefaultImpl(aCpeFactory);
    }
    throw new ResourceConfigurationException(InvalidXMLException.REQUIRED_ATTRIBUTE_MISSING,
View Full Code Here


          CpeCasProcessor aCasProcessorConfig, ProcessControllerAdapter aPca)
          throws ResourceConfigurationException {
    String deployMode = aCasProcessorConfig.getDeployment();

    if (Constants.DEPLOYMENT_LOCAL.equals(deployMode)) {
      return new VinciCasProcessorDeployer(aCpeFactory);
    } else if (Constants.DEPLOYMENT_REMOTE.equals(deployMode)) {
      String protocol = getProtocol(aCasProcessorConfig, aCpeFactory.getResourceManager());
      if (protocol == null || protocol.trim().length() == 0) {
        throw new ResourceConfigurationException(CPMUtils.CPM_LOG_RESOURCE_BUNDLE,
                "UIMA_CPM_invalid_service_descriptor__SEVERE", new Object[] {
                    Thread.currentThread().getName(), "<uriSpecifier>", "<protocol>" },
                new Exception(CpmLocalizedMessage.getLocalizedMessage(
                        CPMUtils.CPM_LOG_RESOURCE_BUNDLE,
                        "UIMA_CPM_EXP_invalid_service_descriptor__WARNING", new Object[] {
                            Thread.currentThread().getName(), aCasProcessorConfig.getName() })));
      } else if (Constants.SOCKET_PROTOCOL.equalsIgnoreCase(protocol)) {
        if (aPca == null) {
          throw new ResourceConfigurationException(
                  ResourceInitializationException.CONFIG_SETTING_ABSENT,
                  new Object[] { "ProcessControllerAdapter" });
        }
        return new SocketCasProcessorDeployer(aPca, aCpeFactory);
      } else {
        // Default is still Vinci
        return new VinciCasProcessorDeployer(aCpeFactory);
      }
    } else if (Constants.DEPLOYMENT_INTEGRATED.equals(deployMode)) {
      return new CPEDeployerDefaultImpl(aCpeFactory);
    }
    throw new ResourceConfigurationException(InvalidXMLException.REQUIRED_ATTRIBUTE_MISSING,
View Full Code Here

          CpeCasProcessor aCasProcessorConfig, ProcessControllerAdapter aPca)
          throws ResourceConfigurationException {
    String deployMode = aCasProcessorConfig.getDeployment();

    if (Constants.DEPLOYMENT_LOCAL.equals(deployMode)) {
      return new VinciCasProcessorDeployer(aCpeFactory);
    } else if (Constants.DEPLOYMENT_REMOTE.equals(deployMode)) {
      String protocol = getProtocol(aCasProcessorConfig);
      if (protocol == null || protocol.trim().length() == 0) {
        throw new ResourceConfigurationException(CPMUtils.CPM_LOG_RESOURCE_BUNDLE,
                "UIMA_CPM_invalid_service_descriptor__SEVERE", new Object[] {
                    Thread.currentThread().getName(), "<uriSpecifier>", "<protocol>" },
                new Exception(CpmLocalizedMessage.getLocalizedMessage(
                        CPMUtils.CPM_LOG_RESOURCE_BUNDLE,
                        "UIMA_CPM_EXP_invalid_service_descriptor__WARNING", new Object[] {
                            Thread.currentThread().getName(), aCasProcessorConfig.getName() })));
      } else if (Constants.SOCKET_PROTOCOL.equalsIgnoreCase(protocol)) {
        if (aPca == null) {
          throw new ResourceConfigurationException(
                  ResourceInitializationException.CONFIG_SETTING_ABSENT,
                  new Object[] { "ProcessControllerAdapter" });
        }
        return new SocketCasProcessorDeployer(aPca, aCpeFactory);
      } else {
        // Default is still Vinci
        return new VinciCasProcessorDeployer(aCpeFactory);
      }
    } else if (Constants.DEPLOYMENT_INTEGRATED.equals(deployMode)) {
      return new CPEDeployerDefaultImpl(aCpeFactory);
    }
    throw new ResourceConfigurationException(InvalidXMLException.REQUIRED_ATTRIBUTE_MISSING,
View Full Code Here

TOP

Related Classes of org.apache.uima.collection.impl.cpm.container.deployer.vinci.VinciCasProcessorDeployer

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.