Futilities/server/backups/db-bak/back burner

From Woozle Writes Code
< Futilities‎ | server‎ | backups‎ | db-bak
Jump to navigation Jump to search

Proposed FerretX API

Manager

Thinking: A "Session" is basically just a set of parameters that will work to start the backup. The PoingyX API exists to assist with ensuring that all the needed parameters are present and valid.

  • function SessionFromSpec(string $uri, string $sPassword, string $fpDest) : Session;

Session

  • function Start() : bool;
  • function CheckStatus() : Status;

The calling process calls Start() to initiate the backup, then repeatedly calls CheckStatus() to see how it's going. This can be reported to an interactive user or just checked for the completion flag.

Status

  • function UnitsDone() : int;
  • function UnitsTotal() : int; // can be zero if unknown
  • function IsDone() : bool;
  • function IsOkay() : bool;
  • function Message() : string;