synology_apm.sdk.models.tiering_plan module

TieringPlan, TieringStatus, and TieringPlanCreateRequest data models.

class synology_apm.sdk.models.tiering_plan.TieringStatus(status, reason, pending_version_count=0, remaining_bytes=None)

Bases: object

Tiering operation status for a Tiering Plan or backup server.

Variables:
  • status (synology_apm.sdk.enums.VersionCopyStatus) – Overall tiering status.

  • reason (synology_apm.sdk.enums.CopyReason | None) – Detail reason when status is SKIPPED, RETRY, or FAILED; None otherwise.

  • pending_version_count (int) – Number of versions waiting to be tiered. Meaningful when IN_PROGRESS, WAITING, RETRY, or FAILED.

  • remaining_bytes (int | None) – Estimated bytes remaining for the pending tiering operation; None when unavailable.

status: VersionCopyStatus
reason: CopyReason | None
pending_version_count: int = 0
remaining_bytes: int | None = None
class synology_apm.sdk.models.tiering_plan.TieringPlan(plan_id, name, description, tiering_after_days, daily_check_time, destination, server_count, tiering_status=None, run_schedule_by_controller_time=False)

Bases: object

Tiering plan configuration for moving backup versions to remote storage.

Variables:
  • plan_id (str) – Unique plan identifier.

  • name (str) – Plan display name.

  • description (str) – Plan description.

  • tiering_after_days (int) – Number of days after which backup versions are moved to the tiering destination.

  • daily_check_time (datetime.time) – Time of day when the tiering check runs (daily).

  • destination (synology_apm.sdk.models.location.LocationInfo | None) – Remote storage destination; None if the destination lookup failed.

  • server_count (int) – Number of backup servers included in this plan.

  • tiering_status (synology_apm.sdk.models.tiering_plan.TieringStatus | None) – Current tiering operation status; None when status is unavailable.

  • run_schedule_by_controller_time (bool) – Whether schedules run on the APM controller’s clock rather than each backup server’s local clock.

plan_id: str
name: str
description: str
tiering_after_days: int
daily_check_time: time
destination: LocationInfo | None
server_count: int
tiering_status: TieringStatus | None = None
run_schedule_by_controller_time: bool = False
class synology_apm.sdk.models.tiering_plan.TieringPlanCreateRequest(name, tier_after_days, destination, daily_check_time=<factory>, description='', run_schedule_by_controller_time=False)

Bases: object

Parameters for creating a Tiering Plan.

Variables:
  • name (str) – Plan display name.

  • tier_after_days (int) – Number of days before versions are moved to the destination.

  • destination (synology_apm.sdk.models.remote_storage.RemoteStorage) – Remote storage destination (from apm.remote_storages).

  • daily_check_time (datetime.time) – Time of day when the tiering check runs.

  • description (str) – Plan description.

  • run_schedule_by_controller_time (bool) – Use APM controller’s clock for scheduling.

name: str
tier_after_days: int
destination: RemoteStorage
daily_check_time: time
description: str = ''
run_schedule_by_controller_time: bool = False