Package ai.fal.client.queue
Class QueueClientImpl
java.lang.Object
ai.fal.client.queue.QueueClientImpl
- All Implemented Interfaces:
QueueClient
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription<O> Output<O> result(String endpointId, QueueResultOptions<O> options) Get the result of a submission.status(String endpointId, QueueStatusOptions options) Check the status of a submission.submit(String endpointId, QueueSubmitOptions options) Submit a payload to an endpoint's queue.subscribeToStatus(String endpointId, QueueSubscribeOptions options) Subscribe to the status of a submission.
-
Constructor Details
-
QueueClientImpl
-
-
Method Details
-
submit
@Nonnull public QueueStatus.InQueue submit(@Nonnull String endpointId, @Nonnull QueueSubmitOptions options) Description copied from interface:QueueClientSubmit a payload to an endpoint's queue.- Specified by:
submitin interfaceQueueClient- Parameters:
endpointId- the endpoint to submit to (e.g. `fal-ai/fast-sdxl`)options- the submit options- Returns:
- the status of the submission with the `requestId` for tracking the submission.
-
status
@Nonnull public QueueStatus.StatusUpdate status(@Nonnull String endpointId, @Nonnull QueueStatusOptions options) Description copied from interface:QueueClientCheck the status of a submission.- Specified by:
statusin interfaceQueueClient- Parameters:
endpointId- the endpoint to cancel the submission foroptions- the status check options- Returns:
- the status of the submission
-
subscribeToStatus
@Nonnull public QueueStatus.Completed subscribeToStatus(@Nonnull String endpointId, @Nonnull QueueSubscribeOptions options) Description copied from interface:QueueClientSubscribe to the status of a submission.- Specified by:
subscribeToStatusin interfaceQueueClient- Parameters:
endpointId- the endpoint to subscribe to the status foroptions- the subscribe options- Returns:
- the status of the submission
-
result
@Nonnull public <O> Output<O> result(@Nonnull String endpointId, @Nonnull QueueResultOptions<O> options) Description copied from interface:QueueClientGet the result of a submission.- Specified by:
resultin interfaceQueueClient- Type Parameters:
O- the type of the output payload- Parameters:
endpointId- the endpoint to get the result foroptions- the response options- Returns:
- the result of the submission
-