java.lang.Object
org.odpi.openmetadata.serverchassis.springboot.config.OMAGConfigHelper

@EnableConfigurationProperties(OMAGServerProperties.class) @Configuration public class OMAGConfigHelper extends Object
This class provides support for loading OMAGServerConfig document from different configuration options/styles. It supports JSON and YAML file based OMAG server configuration; Additionally provides EXPERIMENTAL feature: configure OMAG server using native spring configuration properties.
  • Constructor Summary

    Constructors
    Constructor
    Description
    OMAGConfigHelper(OMAGServerProperties properties, com.fasterxml.jackson.databind.ObjectMapper jsonObjectMapper, com.fasterxml.jackson.databind.ObjectMapper yamlObjectMapper)
    Constructor that injects required beans such as omag application properties and jackson object mappers.
  • Method Summary

    Modifier and Type
    Method
    Description
    org.odpi.openmetadata.adminservices.configuration.properties.OMAGServerConfig
     
     
    void
    Implements logic for deciding proper configuration source and loading its content into OMAGServerConfig configuration object

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • OMAGConfigHelper

      @Autowired public OMAGConfigHelper(OMAGServerProperties properties, @Qualifier("jsonObjectMapper") com.fasterxml.jackson.databind.ObjectMapper jsonObjectMapper, @Qualifier("yamlObjectMapper") com.fasterxml.jackson.databind.ObjectMapper yamlObjectMapper)
      Constructor that injects required beans such as omag application properties and jackson object mappers.
      Parameters:
      properties - application properties prefixed with 'omag.'
      jsonObjectMapper - pre-configured object mapper bean for json processing
      yamlObjectMapper - pre-configured object mapper bean for yaml processing
  • Method Details

    • loadConfig

      public void loadConfig() throws OMAGServerActivationError
      Implements logic for deciding proper configuration source and loading its content into OMAGServerConfig configuration object
      Throws:
      OMAGServerActivationError
    • getServerProperties

      public OMAGServerProperties getServerProperties()
    • getOmagServerConfig

      public org.odpi.openmetadata.adminservices.configuration.properties.OMAGServerConfig getOmagServerConfig()