You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
Discord webhooks have a 1024 character limit for the value field. The current implementation exceeds this causing notifications to Discord to fail.
Messages sent to Discord need to be split into multiple 1024-character messages.
To Reproduce
Cause a CrashLoopBackOff on a pod that is within the monitoring scope of kwatch.
Expected behavior
A notification successfully sent to Discord via the configured webhook.
Actual behavior
Error is logged within kwatch in regards to a failed notification due to exceeding the 1024 character limit.
level=error msg="failed to send event with Discord: HTTP 400 Bad Request, {\"code\": 50035, \"errors\": {\"embeds\": {\"0\": {\"fields\": {\"6\": {\"value\": {\"_errors\": [{\"code\": \"BASE_TYPE_MAX_LENGTH\", \"message\": \"Must be 1024 or fewer in length.\"}]}}}}}}, \"message\": \"Invalid Form Body\"}"
Version/Commit
0.8.0
The text was updated successfully, but these errors were encountered:
Describe the bug
Discord webhooks have a 1024 character limit for the value field. The current implementation exceeds this causing notifications to Discord to fail.
Messages sent to Discord need to be split into multiple 1024-character messages.
Reference:
https://birdie0.github.io/discord-webhooks-guide/other/field_limits.html
https://discord.com/developers/docs/resources/channel#embed-object-embed-field-structure
To Reproduce
Cause a CrashLoopBackOff on a pod that is within the monitoring scope of kwatch.
Expected behavior
A notification successfully sent to Discord via the configured webhook.
Actual behavior
Error is logged within kwatch in regards to a failed notification due to exceeding the 1024 character limit.
level=error msg="failed to send event with Discord: HTTP 400 Bad Request, {\"code\": 50035, \"errors\": {\"embeds\": {\"0\": {\"fields\": {\"6\": {\"value\": {\"_errors\": [{\"code\": \"BASE_TYPE_MAX_LENGTH\", \"message\": \"Must be 1024 or fewer in length.\"}]}}}}}}, \"message\": \"Invalid Form Body\"}"
Version/Commit
0.8.0
The text was updated successfully, but these errors were encountered: