@@ -238,8 +238,20 @@ type ServerConfig struct {
238
238
EnabledSchedulers []string `mapstructure:"enabled_schedulers"`
239
239
240
240
// NodeGCThreshold controls how "old" a node must be to be collected by GC.
241
+ // Age is not the only requirement for a node to be GCed but the threshold
242
+ // can be used to filter by age.
241
243
NodeGCThreshold string `mapstructure:"node_gc_threshold"`
242
244
245
+ // JobGCThreshold controls how "old" a job must be to be collected by GC.
246
+ // Age is not the only requirement for a Job to be GCed but the threshold
247
+ // can be used to filter by age.
248
+ JobGCThreshold string `mapstructure:"job_gc_threshold"`
249
+
250
+ // EvalGCThreshold controls how "old" an eval must be to be collected by GC.
251
+ // Age is not the only requirement for a eval to be GCed but the threshold
252
+ // can be used to filter by age.
253
+ EvalGCThreshold string `mapstructure:"eval_gc_threshold"`
254
+
243
255
// HeartbeatGrace is the grace period beyond the TTL to account for network,
244
256
// processing delays and clock skew before marking a node as "down".
245
257
HeartbeatGrace string `mapstructure:"heartbeat_grace"`
@@ -834,6 +846,12 @@ func (a *ServerConfig) Merge(b *ServerConfig) *ServerConfig {
834
846
if b .NodeGCThreshold != "" {
835
847
result .NodeGCThreshold = b .NodeGCThreshold
836
848
}
849
+ if b .JobGCThreshold != "" {
850
+ result .JobGCThreshold = b .JobGCThreshold
851
+ }
852
+ if b .EvalGCThreshold != "" {
853
+ result .EvalGCThreshold = b .EvalGCThreshold
854
+ }
837
855
if b .HeartbeatGrace != "" {
838
856
result .HeartbeatGrace = b .HeartbeatGrace
839
857
}
0 commit comments