Class DefaultValuesConfigProvider

java.lang.Object
org.a2aproject.sdk.server.config.DefaultValuesConfigProvider
All Implemented Interfaces:
A2AConfigProvider

@ApplicationScoped public class DefaultValuesConfigProvider extends Object implements A2AConfigProvider
Default configuration provider that loads values from META-INF/a2a-defaults.properties files on the classpath.

Each module (server-common, extras, etc.) can contribute a META-INF/a2a-defaults.properties file with default configuration values. All files are discovered and merged at startup.

If duplicate keys are found across different properties files, initialization will fail with an exception to prevent ambiguous configuration.

  • Constructor Details

    • DefaultValuesConfigProvider

      public DefaultValuesConfigProvider()
  • Method Details

    • getValue

      public String getValue(String name)
      Description copied from interface: A2AConfigProvider
      Get a required configuration value.
      Specified by:
      getValue in interface A2AConfigProvider
      Parameters:
      name - the configuration property name
      Returns:
      the configuration value
    • getOptionalValue

      public Optional<String> getOptionalValue(String name)
      Description copied from interface: A2AConfigProvider
      Get an optional configuration value.
      Specified by:
      getOptionalValue in interface A2AConfigProvider
      Parameters:
      name - the configuration property name
      Returns:
      an Optional containing the value if present, empty otherwise