Class TaskStatusPollRequest
java.lang.Object
ai.docling.serve.api.task.request.TaskStatusPollRequest
Represents a request for polling the status of a task.
This class encapsulates the information required to poll the status of a specific task.
It includes the unique task identifier and an optional wait time between consecutive
polling attempts. Instances of this class are immutable and can be built using the
provided builder methods.
Attributes:
- `DEFAULT_STATUS_POLL_WAIT_TIME`: Specifies the default value for the wait time
between polling attempts. By default, this is set to
Duration.ZERO, indicating
no delay between consecutive polling attempts.
- `taskId`: The unique identifier of the task whose status is being polled. This field is
mandatory and must not be null.
- `waitTime`: The duration to wait between consecutive polling attempts. If not explicitly
set, it defaults to DEFAULT_STATUS_POLL_WAIT_TIME.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classstatic classBuilder for creatingTaskStatusPollRequestinstances. -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final DurationThe default wait time between status polling attempts for a task. -
Method Summary
Modifier and TypeMethodDescriptionstatic @NonNull TaskStatusPollRequest.Builderbuilder()@NonNull StringThe unique identifier of the task whose status is being polled.@NonNull DurationThe duration to wait between consecutive polling attempts.@NonNull TaskStatusPollRequest.Builder@NonNull StringtoString()
-
Field Details
-
DEFAULT_STATUS_POLL_WAIT_TIME
The default wait time between status polling attempts for a task.This value is used when no explicit wait time is specified in a
TaskStatusPollRequestinstance. It is set toDuration.ZERO, meaning there is no delay by default between consecutive polling attempts.
-
-
Method Details