Sync Background Task Builders

Synchronous background dataset task builders (delegate to aio.background).

class aerospike_sdk.sync.background.SyncBackgroundWriteBinBuilder[source]

Bases: object

Per-bin scalar write inside a background operation (sync).

__init__(inner, loop_manager)[source]
set_to(value)[source]

Set the bin to value (sync wrapper).

Return type:

SyncBackgroundOperationBuilder

add(value)[source]

Numeric increment (sync wrapper).

Return type:

SyncBackgroundOperationBuilder

class aerospike_sdk.sync.background.SyncBackgroundOperationBuilder[source]

Bases: object

Configure a background update/delete/touch job (sync).

__init__(inner, loop_manager)[source]
where(expression)[source]
Overloads:
  • self, expression (str) → SyncBackgroundOperationBuilder

  • self, expression (FilterExpression) → SyncBackgroundOperationBuilder

Restrict the scan with an AEL or filter predicate.

bin(name)[source]
Return type:

SyncBackgroundWriteBinBuilder

expire_record_after_seconds(seconds)[source]

Set record TTL for the background job.

Return type:

SyncBackgroundOperationBuilder

records_per_second(rps)[source]

Store a throttle hint.

Return type:

SyncBackgroundOperationBuilder

fail_on_filtered_out()[source]
Return type:

SyncBackgroundOperationBuilder

respond_all_keys()[source]

Unsupported for background tasks.

Return type:

SyncBackgroundOperationBuilder

execute()[source]

Submit the job and return a task handle (blocks until accepted).

See also

execute()

Return type:

ExecuteTask

class aerospike_sdk.sync.background.SyncBackgroundUdfFunctionBuilder[source]

Bases: object

Select UDF package/function for a background dataset run (sync).

__init__(inner, loop_manager)[source]
function(package_name, function_name)[source]

Select the UDF package and Lua function.

Return type:

SyncBackgroundUdfBuilder

class aerospike_sdk.sync.background.SyncBackgroundUdfBuilder[source]

Bases: object

Arguments, filters, and throttle for background UDF execution (sync).

__init__(inner, loop_manager)[source]
passing(*args)[source]
Return type:

SyncBackgroundUdfBuilder

where(expression)[source]
Overloads:
  • self, expression (str) → SyncBackgroundUdfBuilder

  • self, expression (FilterExpression) → SyncBackgroundUdfBuilder

Optional predicate limiting which records invoke the UDF.

records_per_second(rps)[source]
Return type:

SyncBackgroundUdfBuilder

fail_on_filtered_out()[source]

Unsupported for background tasks.

Return type:

SyncBackgroundUdfBuilder

respond_all_keys()[source]

Unsupported for background tasks.

Return type:

SyncBackgroundUdfBuilder

execute()[source]

Submit the background UDF job (blocks until accepted).

See also

execute()

Return type:

ExecuteTask

class aerospike_sdk.sync.background.SyncBackgroundTaskSession[source]

Bases: object

Sync entry for server-side dataset background operations.

Obtained from background_task(). Each method returns a sync builder that mirrors BackgroundTaskSession.

Examples

session.background_task().update(dataset).bin(“x”).set_to(1).execute() session.background_task().execute_udf(dataset).function(“pkg”, “fn”).execute()

__init__(inner, loop_manager)[source]
update(dataset)[source]
Return type:

SyncBackgroundOperationBuilder

delete(dataset)[source]

Start a background delete over dataset.

Return type:

SyncBackgroundOperationBuilder

touch(dataset)[source]

Start a background touch (TTL refresh) over dataset.

Return type:

SyncBackgroundOperationBuilder

execute_udf(dataset)[source]

Start a background UDF over dataset.

Return type:

SyncBackgroundUdfFunctionBuilder