upgrade http client
This commit is contained in:
20
httpclient/define/cache.go
Normal file
20
httpclient/define/cache.go
Normal file
@ -0,0 +1,20 @@
|
||||
// Package define ...
|
||||
//
|
||||
// Description : define ...
|
||||
//
|
||||
// Author : go_developer@163.com<白茶清欢>
|
||||
//
|
||||
// Date : 2024-10-09 18:39
|
||||
package define
|
||||
|
||||
// CachePreHeatConfig 缓存预热配置, MinPercent / MinTTL 同时配置, 则任意一个满足, 均进行预热
|
||||
//
|
||||
// Author : go_developer@163.com<白茶清欢>
|
||||
//
|
||||
// Date : 18:40 2024/10/9
|
||||
type CachePreHeatConfig struct {
|
||||
Enable bool `json:"enable"` // 缓存预热是否可用
|
||||
MinPercent int64 `json:"min_percent"` // 最小百分比, 剩余有效期低于此百分比进行预热
|
||||
MinTTL int64 `json:"min_ttl"` // 最小剩余生命周期, 低于此百分比进行预热
|
||||
Force bool `json:"force"` // 启用预热的情况下, 强制预热, 会忽略 MinPercent / MinTTL 的配置
|
||||
}
|
Reference in New Issue
Block a user