mirror of
https://github.com/Caraxi/mare.client.git
synced 2025-12-12 21:57:22 +01:00
add performance logging on demand, fix minion issues
This commit is contained in:
parent
6cf0ecdef1
commit
44450b24b4
29 changed files with 580 additions and 294 deletions
|
|
@ -45,7 +45,7 @@ public class ConfigurationMigrator
|
|||
{
|
||||
_logger.LogInformation("Migrating Configuration from version 0 to 1");
|
||||
if (File.Exists(ConfigurationPath(MareConfigService.ConfigName)))
|
||||
File.Copy(ConfigurationPath(MareConfigService.ConfigName), ConfigurationPath(MareConfigService.ConfigName) + ".migrated." + mareConfigV0.Version + ".bak", true);
|
||||
File.Copy(ConfigurationPath(MareConfigService.ConfigName), ConfigurationPath(MareConfigService.ConfigName) + ".migrated." + mareConfigV0.Version + ".bak", overwrite: true);
|
||||
|
||||
MareConfig mareConfigV1 = mareConfigV0.ToV1();
|
||||
|
||||
|
|
|
|||
|
|
@ -102,7 +102,7 @@ public abstract class ConfigurationServiceBase<T> : IDisposable where T : IMareC
|
|||
|
||||
try
|
||||
{
|
||||
File.Copy(ConfigurationPath, ConfigurationPath + ".bak." + DateTime.Now.ToString("yyyyMMddHHmmss"), true);
|
||||
File.Copy(ConfigurationPath, ConfigurationPath + ".bak." + DateTime.Now.ToString("yyyyMMddHHmmss"), overwrite: true);
|
||||
}
|
||||
catch { }
|
||||
|
||||
|
|
|
|||
|
|
@ -26,4 +26,5 @@ public class MareConfig : IMareConfiguration
|
|||
public NotificationLocation WarningNotification { get; set; } = NotificationLocation.Both;
|
||||
public NotificationLocation ErrorNotification { get; set; } = NotificationLocation.Both;
|
||||
public LogLevel LogLevel { get; set; } = LogLevel.Information;
|
||||
public bool LogPerformance { get; set; } = false;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -11,8 +11,6 @@ namespace MareSynchronos.MareConfiguration.Configurations.Obsolete;
|
|||
public class Configuration : IPluginConfiguration
|
||||
{
|
||||
public int Version { get; set; } = 6;
|
||||
[NonSerialized]
|
||||
private DalamudPluginInterface? _pluginInterface;
|
||||
public Dictionary<string, ServerStorageV0> ServerStorage { get; set; } = new(StringComparer.OrdinalIgnoreCase)
|
||||
{
|
||||
{ ApiController.MainServiceUri, new ServerStorageV0() { ServerName = ApiController.MainServer, ServerUri = ApiController.MainServiceUri } },
|
||||
|
|
@ -55,12 +53,6 @@ public class Configuration : IPluginConfiguration
|
|||
public Dictionary<string, HashSet<string>> ServerAvailablePairTags = new(StringComparer.Ordinal);
|
||||
public HashSet<string> OpenPairTags = new(StringComparer.Ordinal);
|
||||
|
||||
|
||||
public void Save()
|
||||
{
|
||||
_pluginInterface!.SavePluginConfig(this);
|
||||
}
|
||||
|
||||
public MareConfigV0 ToMareConfig(ILogger logger)
|
||||
{
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue