diff --git a/src/ARKServerManager/Config.Designer.cs b/src/ARKServerManager/Config.Designer.cs
index eccdf644..75c138ee 100644
--- a/src/ARKServerManager/Config.Designer.cs
+++ b/src/ARKServerManager/Config.Designer.cs
@@ -1402,7 +1402,37 @@ namespace ServerManagerTool {
this["AutoBackup_BackupPeriod"] = value;
}
}
-
+
+ [global::System.Configuration.UserScopedSettingAttribute()]
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ [global::System.Configuration.DefaultSettingValueAttribute("True")]
+ public bool AutoBackup_ParallelBackup
+ {
+ get
+ {
+ return ((bool)(this["AutoBackup_ParallelBackup"]));
+ }
+ set
+ {
+ this["AutoBackup_ParallelBackup"] = value;
+ }
+ }
+
+ [global::System.Configuration.UserScopedSettingAttribute()]
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ [global::System.Configuration.DefaultSettingValueAttribute("10")]
+ public int AutoBackup_SequencialDelayPeriod
+ {
+ get
+ {
+ return ((int)(this["AutoBackup_SequencialDelayPeriod"]));
+ }
+ set
+ {
+ this["AutoBackup_SequencialDelayPeriod"] = value;
+ }
+ }
+
[global::System.Configuration.UserScopedSettingAttribute()]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Configuration.DefaultSettingValueAttribute("False")]
diff --git a/src/ARKServerManager/Globalization/en-US/en-US.xaml b/src/ARKServerManager/Globalization/en-US/en-US.xaml
index b5ad4a0b..87305eee 100644
--- a/src/ARKServerManager/Globalization/en-US/en-US.xaml
+++ b/src/ARKServerManager/Globalization/en-US/en-US.xaml
@@ -657,6 +657,10 @@
If enabled, when the auto-update is performed all servers will be updated at the same time, otherwise each server will be updated one after the other (this will take more time to complete).
Delay between each server update
The amount of time to wait in between each server update, only available if Parallel Update is disabled.
+ Backup servers in parallel
+ If enabled, when the auto-backup is performed all servers will be backup at the same time, otherwise each server will be backup one after the other (this could produce less server lags).
+ Delay between each server backup
+ The amount of time to wait in between each server backup, only available if Parallel Backup is disabled.
Auto Restart Options
The grace period does not prevent auto-updates from restarting your server.
diff --git a/src/ARKServerManager/Lib/ServerApp.cs b/src/ARKServerManager/Lib/ServerApp.cs
index f572b02a..42fc3536 100644
--- a/src/ARKServerManager/Lib/ServerApp.cs
+++ b/src/ARKServerManager/Lib/ServerApp.cs
@@ -3391,18 +3391,43 @@ namespace ServerManagerTool.Lib
var profiles = _profiles.Keys.Where(p => p.EnableAutoBackup);
var exitCodes = new ConcurrentDictionary();
- Parallel.ForEach(profiles, profile => {
- var app = new ServerApp
+
+ if (Config.Default.AutoBackup_ParallelBackup)
+ {
+ Parallel.ForEach(profiles, profile => {
+ var app = new ServerApp
+ {
+ DeleteOldBackupFiles = Config.Default.AutoBackup_DeleteOldFiles,
+ OutputLogs = true,
+ SendAlerts = true,
+ SendEmails = true,
+ ServerProcess = ServerProcessType.AutoBackup
+ };
+ app.PerformProfileBackup(profile, CancellationToken.None);
+ exitCodes.TryAdd(profile, app.ExitCode);
+ });
+ }
+ else
+ {
+ var delay = 0;
+ foreach (ServerProfileSnapshot profile in profiles)
{
- DeleteOldBackupFiles = Config.Default.AutoBackup_DeleteOldFiles,
- OutputLogs = true,
- SendAlerts = true,
- SendEmails = true,
- ServerProcess = ServerProcessType.AutoBackup
- };
- app.PerformProfileBackup(profile, CancellationToken.None);
- exitCodes.TryAdd(profile, app.ExitCode);
- });
+ if (delay > 0)
+ Task.Delay(delay * 1000).Wait();
+ delay = Math.Max(0, Config.Default.AutoBackup_SequencialDelayPeriod);
+
+ var app = new ServerApp
+ {
+ DeleteOldBackupFiles = Config.Default.AutoBackup_DeleteOldFiles,
+ OutputLogs = true,
+ SendAlerts = true,
+ SendEmails = true,
+ ServerProcess = ServerProcessType.AutoBackup
+ };
+ app.PerformProfileBackup(profile, CancellationToken.None);
+ exitCodes.TryAdd(profile, app.ExitCode);
+ }
+ }
foreach (var profile in _profiles.Keys)
{
diff --git a/src/ARKServerManager/UserControls/GlobalSettingsControl.xaml b/src/ARKServerManager/UserControls/GlobalSettingsControl.xaml
index ff550d39..9cdd1ace 100644
--- a/src/ARKServerManager/UserControls/GlobalSettingsControl.xaml
+++ b/src/ARKServerManager/UserControls/GlobalSettingsControl.xaml
@@ -419,6 +419,9 @@
+
+
+