Interface FleetData.Builder

    • Method Detail

      • activityStatus

        FleetData.Builder activityStatus​(String activityStatus)

        The progress of the EC2 Fleet. If there is an error, the status is error. After all requests are placed, the status is pending_fulfillment. If the size of the EC2 Fleet is equal to or greater than its target capacity, the status is fulfilled. If the size of the EC2 Fleet is decreased, the status is pending_termination while instances are terminating.

        Parameters:
        activityStatus - The progress of the EC2 Fleet. If there is an error, the status is error. After all requests are placed, the status is pending_fulfillment. If the size of the EC2 Fleet is equal to or greater than its target capacity, the status is fulfilled. If the size of the EC2 Fleet is decreased, the status is pending_termination while instances are terminating.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        FleetActivityStatus, FleetActivityStatus
      • activityStatus

        FleetData.Builder activityStatus​(FleetActivityStatus activityStatus)

        The progress of the EC2 Fleet. If there is an error, the status is error. After all requests are placed, the status is pending_fulfillment. If the size of the EC2 Fleet is equal to or greater than its target capacity, the status is fulfilled. If the size of the EC2 Fleet is decreased, the status is pending_termination while instances are terminating.

        Parameters:
        activityStatus - The progress of the EC2 Fleet. If there is an error, the status is error. After all requests are placed, the status is pending_fulfillment. If the size of the EC2 Fleet is equal to or greater than its target capacity, the status is fulfilled. If the size of the EC2 Fleet is decreased, the status is pending_termination while instances are terminating.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        FleetActivityStatus, FleetActivityStatus
      • createTime

        FleetData.Builder createTime​(Instant createTime)

        The creation date and time of the EC2 Fleet.

        Parameters:
        createTime - The creation date and time of the EC2 Fleet.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • fleetId

        FleetData.Builder fleetId​(String fleetId)

        The ID of the EC2 Fleet.

        Parameters:
        fleetId - The ID of the EC2 Fleet.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • fleetState

        FleetData.Builder fleetState​(String fleetState)

        The state of the EC2 Fleet.

        Parameters:
        fleetState - The state of the EC2 Fleet.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        FleetStateCode, FleetStateCode
      • clientToken

        FleetData.Builder clientToken​(String clientToken)

        Unique, case-sensitive identifier that you provide to ensure the idempotency of the request. For more information, see Ensuring idempotency.

        Constraints: Maximum 64 ASCII characters

        Parameters:
        clientToken - Unique, case-sensitive identifier that you provide to ensure the idempotency of the request. For more information, see Ensuring idempotency.

        Constraints: Maximum 64 ASCII characters

        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • excessCapacityTerminationPolicy

        FleetData.Builder excessCapacityTerminationPolicy​(String excessCapacityTerminationPolicy)

        Indicates whether running instances should be terminated if the target capacity of the EC2 Fleet is decreased below the current size of the EC2 Fleet.

        Supported only for fleets of type maintain.

        Parameters:
        excessCapacityTerminationPolicy - Indicates whether running instances should be terminated if the target capacity of the EC2 Fleet is decreased below the current size of the EC2 Fleet.

        Supported only for fleets of type maintain.

        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        FleetExcessCapacityTerminationPolicy, FleetExcessCapacityTerminationPolicy
      • excessCapacityTerminationPolicy

        FleetData.Builder excessCapacityTerminationPolicy​(FleetExcessCapacityTerminationPolicy excessCapacityTerminationPolicy)

        Indicates whether running instances should be terminated if the target capacity of the EC2 Fleet is decreased below the current size of the EC2 Fleet.

        Supported only for fleets of type maintain.

        Parameters:
        excessCapacityTerminationPolicy - Indicates whether running instances should be terminated if the target capacity of the EC2 Fleet is decreased below the current size of the EC2 Fleet.

        Supported only for fleets of type maintain.

        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        FleetExcessCapacityTerminationPolicy, FleetExcessCapacityTerminationPolicy
      • fulfilledCapacity

        FleetData.Builder fulfilledCapacity​(Double fulfilledCapacity)

        The number of units fulfilled by this request compared to the set target capacity.

        Parameters:
        fulfilledCapacity - The number of units fulfilled by this request compared to the set target capacity.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • fulfilledOnDemandCapacity

        FleetData.Builder fulfilledOnDemandCapacity​(Double fulfilledOnDemandCapacity)

        The number of units fulfilled by this request compared to the set target On-Demand capacity.

        Parameters:
        fulfilledOnDemandCapacity - The number of units fulfilled by this request compared to the set target On-Demand capacity.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • launchTemplateConfigs

        FleetData.Builder launchTemplateConfigs​(Collection<FleetLaunchTemplateConfig> launchTemplateConfigs)

        The launch template and overrides.

        Parameters:
        launchTemplateConfigs - The launch template and overrides.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • launchTemplateConfigs

        FleetData.Builder launchTemplateConfigs​(FleetLaunchTemplateConfig... launchTemplateConfigs)

        The launch template and overrides.

        Parameters:
        launchTemplateConfigs - The launch template and overrides.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • targetCapacitySpecification

        FleetData.Builder targetCapacitySpecification​(TargetCapacitySpecification targetCapacitySpecification)

        The number of units to request. You can choose to set the target capacity in terms of instances or a performance characteristic that is important to your application workload, such as vCPUs, memory, or I/O. If the request type is maintain, you can specify a target capacity of 0 and add capacity later.

        Parameters:
        targetCapacitySpecification - The number of units to request. You can choose to set the target capacity in terms of instances or a performance characteristic that is important to your application workload, such as vCPUs, memory, or I/O. If the request type is maintain, you can specify a target capacity of 0 and add capacity later.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • terminateInstancesWithExpiration

        FleetData.Builder terminateInstancesWithExpiration​(Boolean terminateInstancesWithExpiration)

        Indicates whether running instances should be terminated when the EC2 Fleet expires.

        Parameters:
        terminateInstancesWithExpiration - Indicates whether running instances should be terminated when the EC2 Fleet expires.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • type

        FleetData.Builder type​(String type)

        The type of request. Indicates whether the EC2 Fleet only requests the target capacity, or also attempts to maintain it. If you request a certain target capacity, EC2 Fleet only places the required requests; it does not attempt to replenish instances if capacity is diminished, and it does not submit requests in alternative capacity pools if capacity is unavailable. To maintain a certain target capacity, EC2 Fleet places the required requests to meet this target capacity. It also automatically replenishes any interrupted Spot Instances. Default: maintain.

        Parameters:
        type - The type of request. Indicates whether the EC2 Fleet only requests the target capacity, or also attempts to maintain it. If you request a certain target capacity, EC2 Fleet only places the required requests; it does not attempt to replenish instances if capacity is diminished, and it does not submit requests in alternative capacity pools if capacity is unavailable. To maintain a certain target capacity, EC2 Fleet places the required requests to meet this target capacity. It also automatically replenishes any interrupted Spot Instances. Default: maintain.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        FleetType, FleetType
      • type

        FleetData.Builder type​(FleetType type)

        The type of request. Indicates whether the EC2 Fleet only requests the target capacity, or also attempts to maintain it. If you request a certain target capacity, EC2 Fleet only places the required requests; it does not attempt to replenish instances if capacity is diminished, and it does not submit requests in alternative capacity pools if capacity is unavailable. To maintain a certain target capacity, EC2 Fleet places the required requests to meet this target capacity. It also automatically replenishes any interrupted Spot Instances. Default: maintain.

        Parameters:
        type - The type of request. Indicates whether the EC2 Fleet only requests the target capacity, or also attempts to maintain it. If you request a certain target capacity, EC2 Fleet only places the required requests; it does not attempt to replenish instances if capacity is diminished, and it does not submit requests in alternative capacity pools if capacity is unavailable. To maintain a certain target capacity, EC2 Fleet places the required requests to meet this target capacity. It also automatically replenishes any interrupted Spot Instances. Default: maintain.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        FleetType, FleetType
      • validFrom

        FleetData.Builder validFrom​(Instant validFrom)

        The start date and time of the request, in UTC format (for example, YYYY-MM-DDTHH:MM:SSZ). The default is to start fulfilling the request immediately.

        Parameters:
        validFrom - The start date and time of the request, in UTC format (for example, YYYY-MM-DDTHH:MM:SSZ). The default is to start fulfilling the request immediately.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • validUntil

        FleetData.Builder validUntil​(Instant validUntil)

        The end date and time of the request, in UTC format (for example, YYYY-MM-DDTHH:MM:SSZ). At this point, no new instance requests are placed or able to fulfill the request. The default end date is 7 days from the current date.

        Parameters:
        validUntil - The end date and time of the request, in UTC format (for example, YYYY-MM-DDTHH:MM:SSZ). At this point, no new instance requests are placed or able to fulfill the request. The default end date is 7 days from the current date.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • replaceUnhealthyInstances

        FleetData.Builder replaceUnhealthyInstances​(Boolean replaceUnhealthyInstances)

        Indicates whether EC2 Fleet should replace unhealthy Spot Instances. Supported only for fleets of type maintain. For more information, see EC2 Fleet health checks in the Amazon EC2 User Guide.

        Parameters:
        replaceUnhealthyInstances - Indicates whether EC2 Fleet should replace unhealthy Spot Instances. Supported only for fleets of type maintain. For more information, see EC2 Fleet health checks in the Amazon EC2 User Guide.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • spotOptions

        FleetData.Builder spotOptions​(SpotOptions spotOptions)

        The configuration of Spot Instances in an EC2 Fleet.

        Parameters:
        spotOptions - The configuration of Spot Instances in an EC2 Fleet.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • onDemandOptions

        FleetData.Builder onDemandOptions​(OnDemandOptions onDemandOptions)

        The allocation strategy of On-Demand Instances in an EC2 Fleet.

        Parameters:
        onDemandOptions - The allocation strategy of On-Demand Instances in an EC2 Fleet.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • tags

        FleetData.Builder tags​(Collection<Tag> tags)

        The tags for an EC2 Fleet resource.

        Parameters:
        tags - The tags for an EC2 Fleet resource.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • tags

        FleetData.Builder tags​(Tag... tags)

        The tags for an EC2 Fleet resource.

        Parameters:
        tags - The tags for an EC2 Fleet resource.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • tags

        FleetData.Builder tags​(Consumer<Tag.Builder>... tags)

        The tags for an EC2 Fleet resource.

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

        When the Consumer completes, SdkBuilder.build() is called immediately and its result is passed to #tags(List).

        Parameters:
        tags - a consumer that will call methods on Tag.Builder
        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        #tags(java.util.Collection)
      • errors

        FleetData.Builder errors​(Collection<DescribeFleetError> errors)

        Information about the instances that could not be launched by the fleet. Valid only when Type is set to instant.

        Parameters:
        errors - Information about the instances that could not be launched by the fleet. Valid only when Type is set to instant.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • errors

        FleetData.Builder errors​(DescribeFleetError... errors)

        Information about the instances that could not be launched by the fleet. Valid only when Type is set to instant.

        Parameters:
        errors - Information about the instances that could not be launched by the fleet. Valid only when Type is set to instant.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • instances

        FleetData.Builder instances​(Collection<DescribeFleetsInstances> instances)

        Information about the instances that were launched by the fleet. Valid only when Type is set to instant.

        Parameters:
        instances - Information about the instances that were launched by the fleet. Valid only when Type is set to instant.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • instances

        FleetData.Builder instances​(DescribeFleetsInstances... instances)

        Information about the instances that were launched by the fleet. Valid only when Type is set to instant.

        Parameters:
        instances - Information about the instances that were launched by the fleet. Valid only when Type is set to instant.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • context

        FleetData.Builder context​(String context)

        Reserved.

        Parameters:
        context - Reserved.
        Returns:
        Returns a reference to this object so that method calls can be chained together.