Tracks UDF package registration progress across the currently active cluster nodes.
Aerospike.register_udf/3 and register_udf/4 return this handle after the
server accepts the upload. The package may still be propagating when the
call returns, so use status/1 or wait/2 before relying on it from
apply_udf/6, query UDFs, or other package consumers.
Summary
Types
Handle returned while a UDF package propagates through the cluster.
Option accepted by wait/2.
Keyword options accepted by wait/2.
Functions
Returns whether the UDF package is visible on every active cluster node.
Blocks until the UDF package is visible on every active node.
Types
@type t() :: %Aerospike.RegisterTask{ conn: Aerospike.cluster(), package_name: String.t() }
Handle returned while a UDF package propagates through the cluster.
Use status/1 for one poll or wait/2 to block until every active node
reports the package. wait/2 accepts :poll_interval and :timeout in
milliseconds.
@type wait_opt() :: {:poll_interval, non_neg_integer()} | {:timeout, non_neg_integer()}
Option accepted by wait/2.
@type wait_opts() :: [wait_opt()]
Keyword options accepted by wait/2.
Functions
@spec status(t()) :: {:ok, :complete | :in_progress} | {:error, Aerospike.Error.t()}
Returns whether the UDF package is visible on every active cluster node.
@spec wait(struct(), keyword()) :: :ok | {:error, Aerospike.Error.t()}
@spec wait(t(), wait_opts()) :: :ok | {:error, Aerospike.Error.t()}
Blocks until the UDF package is visible on every active node.
Supported options:
:poll_interval— milliseconds to sleep between status checks. Defaults to1_000.:timeout— maximum milliseconds to wait. When omitted, polling continues until registration completes or returns an error.