feat: log specific message for RequestEntityTooLarge#1185
Conversation
Semver Impact of This PR🟡 Minor (new features) 📋 Changelog PreviewThis is how your changes will appear in the changelog. New Features ✨
🤖 This preview updates automatically when you update the PR. |
f1d5214 to
2b92b0f
Compare
2b92b0f to
c0f00e7
Compare
9783918 to
52a9a26
Compare
cf3c519 to
0fb5411
Compare
0fb5411 to
7513a3d
Compare
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.
| description = fmt.Sprintf("%s event", event.Type) | ||
| } | ||
| return fmt.Sprintf("%s [%s]", description, event.EventID) | ||
| } |
There was a problem hiding this comment.
Duplicated event-type-to-description mapping logic
Low Severity
The eventIdentifier function in util.go and EnvelopeIdentifier in internal/util/util.go contain nearly identical logic for mapping event types to human-readable descriptions (error → "error", transaction → "transaction", check-in → "check-in", logs → "%d log events", metrics → "%d metric events"). Both return the same format "%s [%s]". If a new event type is added or the description format changes, both functions must be updated, risking inconsistency.


Description
Handle the RequestEntityTooLarge (413) response from relay and log a debug message so that users can understand envelope size rejections.
Extracting the httpResponse handling as an extra method for reuse.
Issues
Changelog Entry Instructions
To add a custom changelog entry, uncomment the section above. Supports:
For more details: custom changelog entries
Reminders
feat:,fix:,ref:,meta:)