Remove rate limit config
This commit is contained in:
@@ -28,8 +28,10 @@ func NetworkTest() {
|
||||
logPath := fmt.Sprintf("logs/network-test-%s-%s.log", dateStr, timeStr)
|
||||
log := logutil.NewLogger(logPath)
|
||||
|
||||
repoClient4 := http.NewHTTPClient("", 0, 1, false, []string{}, os.Getenv("PROXY"), log.Named("network_test"))
|
||||
repoClient6 := http.NewHTTPClient("", 0, 1, true, []string{}, os.Getenv("PROXY"), log.Named("network_test"))
|
||||
proxyURL := os.Getenv("PROXY")
|
||||
|
||||
repoClient4 := http.NewHTTPClient("", 0, 1, false, []string{}, proxyURL, log.Named("network_test"))
|
||||
repoClient6 := http.NewHTTPClient("", 0, 1, true, []string{}, proxyURL, log.Named("network_test"))
|
||||
repo := http.NewIPRepository(repoClient4, repoClient6, log.Named("network_test"))
|
||||
repo.NetworkTest(true)
|
||||
}
|
||||
|
||||
@@ -30,7 +30,6 @@ type ConfigInterface interface {
|
||||
GetApiTimeoutSecs() int
|
||||
GetDownloadTimeoutSecs() int
|
||||
GetRetriesUntilFailed() int
|
||||
GetRateLimitSleepSecs() int
|
||||
GetRarAction() string
|
||||
GetDownloadsEveryMins() int
|
||||
GetDumpTorrentsEveryMins() int
|
||||
@@ -55,8 +54,6 @@ type ZurgConfig struct {
|
||||
Password string `yaml:"password" json:"password"`
|
||||
PlayableExtensions []string `yaml:"addl_playable_extensions" json:"addl_playable_extensions"`
|
||||
Port string `yaml:"port" json:"port"`
|
||||
Proxy string `yaml:"proxy" json:"proxy"`
|
||||
RateLimitSleepSecs int `yaml:"rate_limit_sleep_secs" json:"rate_limit_sleep_secs"`
|
||||
RefreshEverySecs int `yaml:"check_for_changes_every_secs" json:"check_for_changes_every_secs"`
|
||||
RepairEveryMins int `yaml:"repair_every_mins" json:"repair_every_mins"`
|
||||
RetainFolderNameExtension bool `yaml:"retain_folder_name_extension" json:"retain_folder_name_extension"`
|
||||
@@ -191,13 +188,6 @@ func (z *ZurgConfig) GetDownloadTimeoutSecs() int {
|
||||
return z.DownloadTimeoutSecs
|
||||
}
|
||||
|
||||
func (z *ZurgConfig) GetRateLimitSleepSecs() int {
|
||||
if z.RateLimitSleepSecs == 0 {
|
||||
return 4
|
||||
}
|
||||
return z.RateLimitSleepSecs
|
||||
}
|
||||
|
||||
// GetRarAction returns the action to take when a rar'ed torrent is found
|
||||
// none: do nothing (mark as unrepairable)
|
||||
// extract: extract the rar'ed torrent
|
||||
|
||||
@@ -170,7 +170,7 @@ func (zr *Handlers) handleHome(resp http.ResponseWriter, req *http.Request) {
|
||||
<td>%s</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td rowspan="21">Config</td>
|
||||
<td rowspan="20">Config</td>
|
||||
<td>Version</td>
|
||||
<td>%s</td>
|
||||
</tr>
|
||||
@@ -230,10 +230,6 @@ func (zr *Handlers) handleHome(resp http.ResponseWriter, req *http.Request) {
|
||||
<td>Download Timeout</td>
|
||||
<td>%d secs</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Rate Limit Sleep for...</td>
|
||||
<td>%d secs</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Retries Until Failed</td>
|
||||
<td>%d</td>
|
||||
@@ -340,7 +336,6 @@ func (zr *Handlers) handleHome(resp http.ResponseWriter, req *http.Request) {
|
||||
response.Config.GetDumpTorrentsEveryMins(),
|
||||
response.Config.GetApiTimeoutSecs(),
|
||||
response.Config.GetDownloadTimeoutSecs(),
|
||||
response.Config.GetRateLimitSleepSecs(),
|
||||
response.Config.GetRetriesUntilFailed(),
|
||||
response.Config.GetNetworkBufferSize(),
|
||||
response.Config.ShouldServeFromRclone(),
|
||||
|
||||
Reference in New Issue
Block a user