回退aria设置

croire 3 years ago
parent 4be9a74816
commit 1dff44f9d4

@ -36,11 +36,11 @@ namespace DownKyi.Core.Aria2cNet.Client.Entity
[JsonProperty("dir")]
public string Dir { get; set; }
[JsonProperty("header")]
public string Header { get; set; }
//[JsonProperty("header")]
//public string Header { get; set; }
[JsonProperty("use-head")]
public string UseHead { get; set; }
//[JsonProperty("use-head")]
//public string UseHead { get; set; }
[JsonProperty("user-agent")]
public string UserAgent { get; set; }

@ -8,7 +8,7 @@ namespace DownKyi.Core.Settings
private readonly AllowStatus isLiftingOfRegion = AllowStatus.YES;
// Aria服务器端口号
private readonly int ariaListenPort = 6801;
private readonly int ariaListenPort = 6800;
// Aria日志等级
private readonly AriaConfigLogLevel ariaLogLevel = AriaConfigLogLevel.INFO;

@ -952,7 +952,7 @@ namespace DownKyi.Services.Download
Token = "downkyi",
LogLevel = SettingsManager.GetInstance().GetAriaLogLevel(),
MaxConcurrentDownloads = SettingsManager.GetInstance().GetAriaMaxConcurrentDownloads(),
MaxConnectionPerServer = 16, // 最大取16
MaxConnectionPerServer = 8, // 最大取16
Split = SettingsManager.GetInstance().GetAriaSplit(),
//MaxTries = 5,
MinSplitSize = 10, // 10MB
@ -983,11 +983,15 @@ namespace DownKyi.Services.Download
{
// 暂停所有下载
var ariaPause = await AriaClient.PauseAllAsync();
#if DEBUG
Core.Utils.Debugging.Console.PrintLine(ariaPause.ToString());
#endif
// 关闭服务器
bool close = AriaServer.CloseServer();
#if DEBUG
Core.Utils.Debugging.Console.PrintLine(close);
#endif
}
/// <summary>
@ -1025,8 +1029,8 @@ namespace DownKyi.Services.Download
//HttpProxy = $"http://{Settings.GetAriaHttpProxy()}:{Settings.GetAriaHttpProxyListenPort()}",
Dir = path,
Out = localFileName,
Header = $"cookie: {LoginHelper.GetLoginInfoCookiesString()}\nreferer: https://www.bilibili.com",
UseHead = "true",
//Header = $"cookie: {LoginHelper.GetLoginInfoCookiesString()}\nreferer: https://www.bilibili.com",
//UseHead = "true",
UserAgent = "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/101.0.4951.54 Safari/537.36",
};

Loading…
Cancel
Save