Interface GlueApplication.Builder<B extends GlueApplication.Builder<B,​A>,​A extends GlueApplication>

    • Method Detail

      • withConfigLoader

        B withConfigLoader​(Supplier<GlueConfig> configLoader)
        Set the configuration loader to use.
        Parameters:
        configLoader - configuration loader to use, not null
        Returns:
        this builder, never null
      • withApplicationName

        B withApplicationName​(String applicationName)
        Set the desired application name.
        Parameters:
        applicationName - name to use, not null
        Returns:
        this builder, never null
        Since:
        1.3
      • withShutdownRequestListener

        B withShutdownRequestListener​(Consumer<Glue> shutDownRequestListener)
        Set shutdown listener.
        Parameters:
        shutDownRequestListener - the listener to use, not null
        Returns:
        this builder, never null
        Since:
        1.3.8
      • buildAsync

        CompletionStage<? extends A> buildAsync()
        Creates the Glue application with the options specified by this builder.
        Returns:
        a stage that completes when the Glue application is fully initialized, never null
      • build

        default A build()
        Convenience method to call buildAsync() and block on the result.
        Returns:
        Glue application instance, never null
        Throws:
        GlueException - if cannot build the instance