Skip to content
This repository has been archived by the owner on Nov 21, 2024. It is now read-only.

webhooks feature - http call, slack #239

Closed
pueding opened this issue Jan 25, 2024 · 0 comments · Fixed by #259
Closed

webhooks feature - http call, slack #239

pueding opened this issue Jan 25, 2024 · 0 comments · Fixed by #259
Assignees
Milestone

Comments

@pueding
Copy link
Member

pueding commented Jan 25, 2024

wave-config.yaml

# Webhooks
webhooks:
  - id: webhook-http
    webhook_type: http
    url: http://localhost:3024/api/test
    headers:
      Authorization: Bearer token
  # https://api.slack.com/messaging/webhooks
  - id: webhook-slack-incoming-webhook
    webhook_type: SlackIncomingWebhook
    url: https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXXXXXXXXXX
  # https://api.slack.com/methods/chat.postMessage
  - id: webhook-slack-oauth (추후 개발)
    webhook_type: SlackOauth
    token: XXX
    channel: XXX

wave-definition.yaml

kind: ScalingPlan
id: cpu-scaling
metadata:
  cool_down: 10
  interval: 1000
  title: Scaling Plan for K8S deployment Scaling - scaling replicas
  webhooks:
    - webhook-1
    - webhook-2
plans:
  - id: plan-scale-1
    ...

Response Values (transfer by plan item & scaling component)

  • Http (fail)
{
    "timestamp": 1709084018,
    "plan_id": "cpu-scaling",
    "plan_item_id": "plan-scale-1",
    "scaling_component": {
        "component_id": "k8s_node_dp",
        "replicas": "$min_pod"
    },
    "status": "FAIL",
    "fail_message": "Invalid target value"
}
  • Http (success)
{
    "timestamp": 1709165350,
    "plan_id": "cpu-scaling",
    "plan_item_id": "plan-scale-1",
    "scaling_component": {
        "component_id": "k8s_node_dp_2",
        "replicas": "1"
    },
    "status": "SUCCESS",
    "fail_message": ""
}
@pueding pueding added type: new-feature type: New feature or request target: definition_file labels Jan 25, 2024
@pueding pueding added this to the v0.2.0 milestone Jan 25, 2024
@pueding pueding self-assigned this Feb 13, 2024
@pueding pueding assigned Ari-suhyeon and unassigned pueding Feb 26, 2024
@Ari-suhyeon Ari-suhyeon linked a pull request Feb 28, 2024 that will close this issue
6 tasks
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants