Skip to content

chore: deprecate templatebody from http check#1587

Draft
adityathebe wants to merge 2 commits into
masterfrom
chore/deprecate-templatebody
Draft

chore: deprecate templatebody from http check#1587
adityathebe wants to merge 2 commits into
masterfrom
chore/deprecate-templatebody

Conversation

@adityathebe

Copy link
Copy Markdown
Member

resolves: #1584

@adityathebe adityathebe requested a review from moshloop January 15, 2024 02:00
@adityathebe

adityathebe commented Jan 16, 2024

Copy link
Copy Markdown
Member Author

To avoid excessive escaping on the templates we might want to simply turn off templating on some fields. Example: we could do it via annotations

apiVersion: canaries.flanksource.com/v1
kind: Canary
metadata:
  name: http-fail
  labels:
    "Expected-Fail": "true"
  annotations:
    canary.template.disabled: 'http.body, http.url' # <-----
spec:
  interval: 30
  http:
    - endpoint: https://httpbin.demo.aws.flanksource.com/status/500
      name: http fail response code check
      responseCodes: [200]
    - endpoint: https://httpbin.demo.aws.flanksource.com/status/200
      name: http fail test expr check
      display:
        expr: string(code) + " should be 500"
      test:
        expr: code == 500

Should this be sufficient

canary.template.disabled: 'http.body, http.url'

or do we want to individually disable templating on the http check. Eg

canary.template.disabled: 'http[0].body, http[1].url'

@moshloop moshloop marked this pull request as draft March 20, 2024 10:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Deprecate the templateBody field in HTTP check spec

1 participant