Skip to content

Commit

Permalink
Merge pull request observatorium#35 from songleo/fix-delete-delay
Browse files Browse the repository at this point in the history
ceil for ignoreDeletionMarksDelay when deleteDelay is odd number
  • Loading branch information
openshift-merge-robot authored Jun 2, 2021
2 parents f213b5c + 495e74c commit bb621bd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion jsonnet/obs-operator.jsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ local operatorObs = obs {
stores+:: {
local deleteDelay = if std.objectHas(cr.spec.thanos, 'compact') && std.objectHas(cr.spec.thanos.compact, 'deleteDelay') then cr.spec.thanos.compact.deleteDelay else obs.thanos.compact.config.deleteDelay,
securityContext: if std.objectHas(cr.spec, 'securityContext') then cr.spec.securityContext else obs.thanos.stores.config.securityContext,
ignoreDeletionMarksDelay: std.parseInt(std.substr(deleteDelay, 0, std.length(deleteDelay) - 1)) / 2 + std.substr(deleteDelay, std.length(deleteDelay) - 1, std.length(deleteDelay)),
ignoreDeletionMarksDelay: std.ceil(std.parseInt(std.substr(deleteDelay, 0, std.length(deleteDelay) - 1)) / 2) + std.substr(deleteDelay, std.length(deleteDelay) - 1, std.length(deleteDelay)),
} + if std.objectHas(cr.spec.thanos, 'store') then cr.spec.thanos.store else {},

storeCache+:: (if std.objectHas(cr.spec.thanos, 'store') && std.objectHas(cr.spec.thanos.store, 'cache') then cr.spec.thanos.store.cache else {}) + {
Expand Down

0 comments on commit bb621bd

Please sign in to comment.