Class ClientConfiguration

    • Constructor Detail

      • ClientConfiguration

        public ClientConfiguration()
    • Method Detail

      • storeId

        public ClientConfiguration storeId​(java.lang.String storeId)
        Set the Store ID.
        Parameters:
        storeId - The URL.
        Returns:
        This object.
      • getStoreId

        public java.lang.String getStoreId()
        Get the Authorization Model ID.
        Returns:
        The Authorization Model ID.
      • authorizationModelId

        public ClientConfiguration authorizationModelId​(java.lang.String authorizationModelId)
        Set the Authorization Model ID.
        Parameters:
        authorizationModelId - The URL.
        Returns:
        This object.
      • getAuthorizationModelId

        public java.lang.String getAuthorizationModelId()
        Get the Authorization Model ID.
        Returns:
        The Authorization Model ID.
      • getAuthorizationModelIdChecked

        public java.lang.String getAuthorizationModelIdChecked()
                                                        throws FgaInvalidParameterException
        Get the Authorization Model ID.
        Returns:
        The Authorization Model ID.
        Throws:
        FgaInvalidParameterException - when the Authorization Model ID is null, empty, or whitespace
      • readTimeout

        public ClientConfiguration readTimeout​(java.time.Duration readTimeout)
        Description copied from class: Configuration
        Set the read timeout for the http client.

        This is the value used by default for each request, though it can be overridden on a per-request basis with a request interceptor.

        Overrides:
        readTimeout in class Configuration
        Parameters:
        readTimeout - The read timeout used by default by the http client. Setting this value to null resets the timeout to an effectively infinite value.
        Returns:
        This object.
      • connectTimeout

        public ClientConfiguration connectTimeout​(java.time.Duration connectTimeout)
        Description copied from class: Configuration
        Sets the connect timeout (in milliseconds) for the http client.

        In the case where a new connection needs to be established, if the connection cannot be established within the given duration, then HttpClient::send throws an HttpConnectTimeoutException, or HttpClient::sendAsync completes exceptionally with an HttpConnectTimeoutException. If a new connection does not need to be established, for example if a connection can be reused from a previous request, then this timeout duration has no effect.

        Overrides:
        connectTimeout in class Configuration
        Parameters:
        connectTimeout - connection timeout in milliseconds
        Returns:
        This object.