cterasdk.lib.tasks module#

class cterasdk.lib.tasks.AwaitableEdgeTask(ctera, ref)#

Bases: AwaitableTask

Awaitable Edge Filer Task Object

async a_status()#

Asynchronous function to retrieve task status.

status()#

Synchronous function to retrieve task status.

class cterasdk.lib.tasks.AwaitablePortalTask(ctera, ref)#

Bases: AwaitableTask

Awaitable Portal Task Object

async a_status()#

Asynchronous function to retrieve task status.

status()#

Synchronous function to retrieve task status.

class cterasdk.lib.tasks.AwaitableTask(ctera, ref)#

Bases: ABC

abstractmethod async a_status()#
async a_wait(timeout=None, poll_interval=None)#

Wait until the given task is complete, or until the timeout expires.

If a positive timeout (in seconds) is specified, this function will block only up to that duration. If timeout is None or non-positive, it will wait indefinitely until the task completes.

Parameters:
  • timeout (float,optional) – Raise exception in the event of a timeout

  • poll_interval (float,optional) – Poll interval, defaults to 1 second

property ref#
abstractmethod status()#
wait(timeout=None, poll_interval=None)#

Wait until the given task is complete, or until the timeout expires.

If a positive timeout (in seconds) is specified, this function will block only up to that duration. If timeout is None or non-positive, it will wait indefinitely until the task completes.

Parameters:
  • timeout (float,optional) – Raise exception in the event of a timeout

  • poll_interval (float,optional) – Poll interval, defaults to 1 second

class cterasdk.lib.tasks.BaseTask(task)#

Bases: Object

Base Task

Variables:
property completed#
property completed_with_warnings#
property failed#
class cterasdk.lib.tasks.EdgeTask(task)#

Bases: BaseTask

Edge Task

Variables:

description (str) – Task description

class cterasdk.lib.tasks.FilesystemTask(task)#

Bases: PortalTask

Filesystem Task

Variables:
  • files_processed (int) – Files processed

  • bytes_processed (int) – Bytes processed

  • total_files (int) – Total files

  • total_bytes (int) – Total bytes

  • error_type (str) – Task error

  • file_in_progress (str) – File in progress

  • user_uid (int) – User UID

  • cursor (cterasdk.common.object.Object) – Cursor

class cterasdk.lib.tasks.PortalTask(task)#

Bases: BaseTask

Portal Task

Variables:
  • progress_str (str) – Task progress description

  • tenant (int) – Tenant UID

unknown_object()#