Class Configuration

java.lang.Object
ch.rasc.jcentserverclient.Configuration

public class Configuration extends Object
Configuration class for Centrifugo Server API Client.

This class holds all configuration settings needed to connect to and interact with a Centrifugo server. It uses the builder pattern for easy and flexible configuration setup.

Key configuration options:

  • API key for authentication
  • Base URL of the Centrifugo server
  • HTTP client configuration
  • Retry policies and timeouts
  • Logging and error handling

Example usage:


 Configuration config = Configuration.builder().apiKey("your-api-key")
 		.baseUrl("http://localhost:8000/api").logLevel(Logger.Level.BASIC).build();
 
Since:
1.0.0
See Also:
  • Method Details

    • builder

      public static Configuration.Builder builder()
      Creates a new configuration builder.
      Returns:
      a new builder instance
    • apiKey

      public String apiKey()
      Gets the configured API key.
      Returns:
      the API key for authentication
    • baseUrl

      public String baseUrl()
      Gets the configured base URL.
      Returns:
      the base URL for API calls
    • client

      public feign.Client client()
      Gets the configured HTTP client.
      Returns:
      the HTTP client implementation
    • retryer

      public feign.Retryer retryer()
      Gets the configured retry policy.
      Returns:
      the retry policy implementation
    • feignOptions

      public feign.Request.Options feignOptions()
      Gets the configured HTTP request options.
      Returns:
      the HTTP request options
    • logger

      public feign.Logger logger()
      Gets the configured logger.
      Returns:
      the logger implementation
    • errorDecoder

      public feign.codec.ErrorDecoder errorDecoder()
      Gets the configured error decoder.
      Returns:
      the error decoder implementation
    • additionalRequestInterceptor

      public feign.RequestInterceptor additionalRequestInterceptor()
      Gets the configured additional request interceptor.
      Returns:
      the additional request interceptor
    • logLevel

      public feign.Logger.Level logLevel()
      Gets the configured logging level.
      Returns:
      the logging level