Interface TargetTrafficSplitEntry.Builder

  • Method Details

    • targetName

      TargetTrafficSplitEntry.Builder targetName(String targetName)

      The name of the target to route traffic to.

      Parameters:
      targetName - The name of the target to route traffic to.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • model

      The model ID to send to the target for this variant. Supported only for inference targets. If you don't specify a model, the gateway sends the model from the original request.

      Parameters:
      model - The model ID to send to the target for this variant. Supported only for inference targets. If you don't specify a model, the gateway sends the model from the original request.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • fallback

      The fallback configuration for this variant. Supported only for inference targets.

      Parameters:
      fallback - The fallback configuration for this variant. Supported only for inference targets.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • fallback

      The fallback configuration for this variant. Supported only for inference targets.

      This is a convenience method that creates an instance of the Fallback.Builder avoiding the need to create one manually via Fallback.builder().

      When the Consumer completes, SdkBuilder.build() is called immediately and its result is passed to fallback(Fallback).

      Parameters:
      fallback - a consumer that will call methods on Fallback.Builder
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also:
    • name

      The name of this traffic split variant.

      Parameters:
      name - The name of this traffic split variant.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • weight

      The percentage of traffic to route to this variant.

      Parameters:
      weight - The percentage of traffic to route to this variant.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • description

      TargetTrafficSplitEntry.Builder description(String description)

      The description of this traffic split variant.

      Parameters:
      description - The description of this traffic split variant.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • metadata

      Key-value metadata associated with this traffic split variant.

      Parameters:
      metadata - Key-value metadata associated with this traffic split variant.
      Returns:
      Returns a reference to this object so that method calls can be chained together.