tgxn / Backup

A Backup plugin for the Bukkit Server API.
http://bukkitbackup.com
GNU General Public License v3.0
23 stars 14 forks source link

Player leave backup schedule not ceasing. #62

Closed tgxn closed 12 years ago

tgxn commented 12 years ago

From: http://forums.bukkit.org/threads/admn-backup-v1-8-5-a-full-simple-backup-plugin-1-0-1-r1.39927/page-8#post-921499

I'm having some interesting issues as of lately (or perhaps I simply never noticed this). It seems that the 'last backup' scheduled when a person leaves starts a secondary schedule alongside the 'once every two hours' schedule I have running. Here's what skipped backups look like before anyone joins.

Code: 2012-01-19 14:34:59 [INFO] [Backup] Skipping backup. (Next: 120 minutes) 2012-01-19 16:34:59 [INFO] [Backup] Skipping backup. (Next: 120 minutes) 2012-01-19 18:34:59 [INFO] [Backup] Skipping backup. (Next: 120 minutes) 2012-01-19 20:34:59 [INFO] [Backup] Skipping backup. (Next: 120 minutes) As expected, it is trying to back up ever two hours. Now, after this, a player joins, plays, and leaves.

Code: 2012-01-19 21:52:33 [INFO] [Backup] Scheduled last backup for 120 minutes; 2012-01-19 22:34:59 [INFO] [Backup] Last player left, backing up! 2012-01-19 22:34:59 [INFO] [Backup] Started Backup... 2012-01-19 22:34:59 [INFO] CONSOLE: Forcing save.. 2012-01-19 22:34:59 [INFO] CONSOLE: Save complete. 2012-01-19 22:34:59 [INFO] CONSOLE: Disabling level saving.. 2012-01-19 22:37:59 [INFO] CONSOLE: Enabling level saving.. 2012-01-19 22:37:59 [INFO] [Backup] Finished Backup! 2012-01-19 23:52:34 [INFO] [Backup] Skipping backup. (Next: 120 minutes) 2012-01-20 00:34:59 [INFO] [Backup] Skipping backup. (Next: 120 minutes) 2012-01-20 01:52:34 [INFO] [Backup] Skipping backup. (Next: 120 minutes) 2012-01-20 02:34:59 [INFO] [Backup] Skipping backup. (Next: 120 minutes) 2012-01-20 03:52:34 [INFO] [Backup] Skipping backup. (Next: 120 minutes) 2012-01-20 04:34:59 [INFO] [Backup] Skipping backup. (Next: 120 minutes) 2012-01-20 05:52:34 [INFO] [Backup] Skipping backup. (Next: 120 minutes) 2012-01-20 06:34:59 [INFO] [Backup] Skipping backup. (Next: 120 minutes) 2012-01-20 07:52:34 [INFO] [Backup] Skipping backup. (Next: 120 minutes) The backup started at the correct time, but this scheduled 'last backup' schedule persisted, and as you can see, the plugin is now trying to backup more frequently, as two schedules appear to be running. Ideally, the plugin should simply attempt to back up every two hours. If players are online, it should run the backup. After all players leave, it should run a backup at the next regularly scheduled attempt, then skip the next backups, until more player activity.