Class NatsConnectionFactoryConfig.JetStreamConfiguration.StreamConfiguration

java.lang.Object
io.micronaut.nats.connect.NatsConnectionFactoryConfig.JetStreamConfiguration.StreamConfiguration
Enclosing class:
NatsConnectionFactoryConfig.JetStreamConfiguration

@EachProperty("streams") public static class NatsConnectionFactoryConfig.JetStreamConfiguration.StreamConfiguration extends Object
Manages a single stream configuration.
  • Constructor Details

    • StreamConfiguration

      public StreamConfiguration(@Parameter String name)
  • Method Details

    • getBuilder

      public io.nats.client.api.StreamConfiguration.Builder getBuilder()
      get the stream configuration builder.
      Returns:
      stream configuration builder
    • toStreamConfiguration

      public io.nats.client.api.StreamConfiguration toStreamConfiguration()
      return the configuration as StreamConfiguration.
      Returns:
      nats stream configuration
    • getSubjects

      public List<String> getSubjects()
      get the subjects of the stream.
      Returns:
      the subjects
    • setSubjects

      public void setSubjects(List<String> subjects)
      set the subjects.
      Parameters:
      subjects - list of subjects
    • isCreateOrUpdate

      public boolean isCreateOrUpdate()
      create or update stream during startup.
      Returns:
      true, if stream should be created or updated
      Since:
      4.4.0
    • setCreateOrUpdate

      public void setCreateOrUpdate(boolean createOrUpdate)
      create or update stream during startup.
      Parameters:
      createOrUpdate - true to create or update stream during startup
      Since:
      4.4.0