Processing Backups Asynchronously

You may often want to process database backups asynchronously, using an asynchronous JADE process.

You can use server applications or the Application class startApplication method to start a new process to perform a backup or you can have separate JADE processes to perform concurrent file backups.

You can schedule backups to occur automatically at a specific time or frequency, by using a JADE timer to start the process.

The DbBackup::doBackup method in the following example calls Application::startAppMethod method to start a new DbAdmin application called DatabaseBackup, starting in the DbAdmin::backupDatabaseProcessor method and passing a reference to a BackupManager instance as the single method parameter.

The DatabaseBackup application is specified with application type of Non-GUI (set from the JADE development environment Define Application dialog), which allows it to run as a background process with no forms. (This method would typically be initiated from a user interface event such as a button-click.)