Share via


NodeRebootPollerAsync Class

  • java.lang.Object
    • com.azure.compute.batch.NodeRebootPollerAsync

public final class NodeRebootPollerAsync

Async poller class used by beginRebootNode to implement polling logic for rebooting a BatchNode. Returns BatchNode values during polling and the final BatchNode upon successful completion.

Constructor Summary

Constructor Description
NodeRebootPollerAsync(BatchAsyncClient batchAsyncClient, String poolId, String nodeId, RequestOptions options)

Creates a new NodeRebootPollerAsync.

Method Summary

Modifier and Type Method and Description
Function<PollingContext<BatchNode>,Mono<PollResponse<BatchNode>>> getActivationOperation()

Activation operation to start the reboot.

BiFunction<PollingContext<BatchNode>,PollResponse<BatchNode>,Mono<BatchNode>> getCancelOperation()

Cancel operation – not supported for reboot.

Function<PollingContext<BatchNode>,Mono<BatchNode>> getFetchResultOperation()

Final-result fetch operation.

Function<PollingContext<BatchNode>,Mono<PollResponse<BatchNode>>> getPollOperation()

Poll operation – watches the node until it leaves rebooting and reaches idle or running.

Methods inherited from java.lang.Object

Constructor Details

NodeRebootPollerAsync

public NodeRebootPollerAsync(BatchAsyncClient batchAsyncClient, String poolId, String nodeId, RequestOptions options)

Creates a new NodeRebootPollerAsync.

Parameters:

batchAsyncClient - The BatchAsyncClient used to interact with the Batch service.
poolId - The ID of the pool that contains the node.
nodeId - The ID of the node to reboot.
options - Optional request options for service calls.

Method Details

getActivationOperation

public Function<PollingContext<BatchNode>,Mono<PollResponse<BatchNode>>> getActivationOperation()

Activation operation to start the reboot.

Returns:

A function that initiates the reboot call and returns a PollResponse<T> with LongRunningOperationStatus#IN_PROGRESS.

getCancelOperation

public BiFunction<PollingContext<BatchNode>,PollResponse<BatchNode>,Mono<BatchNode>> getCancelOperation()

Cancel operation – not supported for reboot.

Returns:

A function that always returns an empty Mono, indicating cancellation is unsupported.

getFetchResultOperation

public Function<PollingContext<BatchNode>,Mono<BatchNode>> getFetchResultOperation()

Final-result fetch operation.

Returns:

A function that returns the final BatchNode from the latest poll response.

getPollOperation

public Function<PollingContext<BatchNode>,Mono<PollResponse<BatchNode>>> getPollOperation()

Poll operation – watches the node until it leaves rebooting and reaches idle or running.

Returns:

A function that polls the node and returns a PollResponse<T> reflecting the current long-running operation status.

Applies to