Class ServiceSetup

java.lang.Object
de.iip_ecosphere.platform.services.ServiceSetup
All Implemented Interfaces:
de.iip_ecosphere.platform.support.setup.PluginsSetup

public class ServiceSetup extends Object implements de.iip_ecosphere.platform.support.setup.PluginsSetup
Basic Yaml configuration options.
Author:
Holger Eichelberger, SSE
  • Field Details

    • ENV_SUPPORTED_APPIDS

      public static final String ENV_SUPPORTED_APPIDS
      See Also:
    • PROPERTY_SUPPORTED_APPIDS

      public static final String PROPERTY_SUPPORTED_APPIDS
      See Also:
    • aas

      private de.iip_ecosphere.platform.support.iip_aas.AasPartRegistry.AasSetup aas
    • serviceProtocol

      private String serviceProtocol
    • transport

      private de.iip_ecosphere.platform.transport.connectors.TransportSetup transport
    • netMgr

      private de.iip_ecosphere.platform.support.net.NetworkManagerSetup netMgr
    • serviceCmdArgs

      private List<String> serviceCmdArgs
    • supportedAppIds

      private List<String> supportedAppIds
    • pluginsFolder

      private String pluginsFolder
    • appPluginsFolder

      private String appPluginsFolder
    • updateAppPlugins

      private boolean updateAppPlugins
  • Constructor Details

    • ServiceSetup

      public ServiceSetup()
  • Method Details

    • initialSupportedAppIds

      private static List<String> initialSupportedAppIds()
      Tries to read the supported App ids from PROPERTY_SUPPORTED_APPIDS as environment variable or java system property.
      Returns:
      the initial App ids, may be empty
    • setPluginsFolder

      public void setPluginsFolder(String pluginsFolder)
      Changes the (parent) folder where the oktoflow plugins are located. [yaml convention]
      Parameters:
      pluginsFolder - the plugins folder
    • setPluginsFolderFile

      public void setPluginsFolderFile(File pluginsFolder)
      Changes the (parent) folder where the oktoflow plugins are located. [yaml convention]
      Parameters:
      pluginsFolder - the plugins folder
    • setAppPluginsFolder

      public void setAppPluginsFolder(String pluginsFolder)
      Changes the (parent) folder where the oktoflow app plugins are located. [yaml convention]
      Parameters:
      pluginsFolder - the plugins folder;
    • setAppPluginsFolderFile

      public void setAppPluginsFolderFile(File pluginsFolder)
      Changes the (parent) folder where the oktoflow app plugins are located. [yaml convention]
      Parameters:
      pluginsFolder - the plugins folder
    • setUpdateAppPlugins

      public void setUpdateAppPlugins(boolean updateAppPlugins)
      Whether app plugins shall be updated. [yaml convention]
      Parameters:
      updateAppPlugins - whether app plugins shall be updated
    • getPluginsFolder

      public String getPluginsFolder()
      Returns the (parent) folder where the oktoflow plugins are located (the folder itself or by default its sub-folders "plugins" or "oktoPlugins").
      Specified by:
      getPluginsFolder in interface de.iip_ecosphere.platform.support.setup.PluginsSetup
      Returns:
      the folder, by default taken from AbstractSetup.PARAM_PLUGINS (env or sys property), fallback "plugins"
    • getAppPluginsFolder

      public String getAppPluginsFolder()
      Returns the (parent) folder where the oktoflow app plugins are located. If not specified, use getPluginsFolder() instead.
      Returns:
      the folder, may be null (then use getPluginsFolder()} instead
    • getUpdateAppPlugins

      public boolean getUpdateAppPlugins()
      Returns whether app plugins shall be updated.
      Returns:
      whether app plugins shall be updated
    • getAas

      public de.iip_ecosphere.platform.support.iip_aas.AasPartRegistry.AasSetup getAas()
      Returns the AAS setup.
      Returns:
      the AAs setup
    • getServiceProtocol

      public String getServiceProtocol()
      Returns the service administration protocol.
      Returns:
      the service administration protocol (see AasFactory.getProtocols()
    • getTransport

      public de.iip_ecosphere.platform.transport.connectors.TransportSetup getTransport()
      Returns the transport setup.
      Returns:
      the transport setup
    • getNetMgr

      public de.iip_ecosphere.platform.support.net.NetworkManagerSetup getNetMgr()
      Returns the network manager setup.
      Returns:
      the network manager setup
    • getServiceCmdArgs

      public List<String> getServiceCmdArgs()
      Returns additional global service command arguments, e.g., for testing.
      Returns:
      additional service command arguments
    • getSupportedAppIds

      public List<String> getSupportedAppIds()
      Returns the supported App Ids.
      Returns:
      the supported App Ids, may be empty for no restriction
    • setAas

      public void setAas(de.iip_ecosphere.platform.support.iip_aas.AasPartRegistry.AasSetup aas)
      Defines the AAS setup. [required by snakeyaml]
      Parameters:
      aas - the AAS setup
    • setServiceProtocol

      public void setServiceProtocol(String serviceProtocol)
      Defines the service administration protocol. [required by snakeyaml]
      Parameters:
      serviceProtocol - the service administration protocol (see AasFactory.getProtocols()
    • setTransport

      public void setTransport(de.iip_ecosphere.platform.transport.connectors.TransportSetup transport)
      Defines the transport setup. [required by snakeyaml]
      Parameters:
      transport - the transport setup
    • setNetMgr

      public void setNetMgr(de.iip_ecosphere.platform.support.net.NetworkManagerSetup netMgr)
      Defines the network manager setup. [required snakeyaml]
      Parameters:
      netMgr - the network manager setup
    • setServiceCmdArgs

      public void setServiceCmdArgs(List<String> serviceCmdArgs)
      Additional global service command arguments, e.g., for testing. [snakeyaml]
      Parameters:
      serviceCmdArgs - the additional command arguments
    • setSupportedAppIds

      public void setSupportedAppIds(List<String> supportedAppIds)
      Changes the supported App Ids. [snakeyaml]
      Parameters:
      supportedAppIds - the supported App Ids, may be empty for no restriction