Skip to content

Fix no address bug and send additional cloud18 info to mattermost hook #1127

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 6 commits into from
Apr 28, 2025

Conversation

caffeinated92
Copy link
Collaborator

@caffeinated92 caffeinated92 commented Apr 28, 2025

This pull request introduces several enhancements and refactors across the codebase, focusing on email notifications, Slack integration, and improved handling of additional fields in alerts. Key changes include the introduction of a new method for sending initialization emails, support for additional fields in Slack messages, and improvements to email recipient handling.

Email Notification Enhancements:

  • Added a new SendClustersInitMail method in server_mail.go to handle initialization emails for clusters, including sponsor-specific emails when Cloud18 is enabled. This centralizes email-sending logic and improves maintainability. [1] [2]
  • Refactored email recipient handling in cluster_mail.go to ensure recipients are properly validated and duplicates are avoided. [1] [2]
  • Updated email-sending logic in cluster_sec.go to include the To field in alert recipients for password rotation notifications. [1] [2]

Slack Integration Enhancements:

  • Added support for AdditionalFields in Slack configurations, allowing custom fields to be included in Slack messages. This was implemented in slackman.go and integrated into cluster and replication manager logic. [1] [2] [3]
  • Enhanced the MeetHook struct in meethook.go to include AdditionalFields and updated the Slack message generation logic to append these fields dynamically. [1] [2] [3]

General Improvements:

  • Improved error handling in alert.go for email-sending failures, providing more detailed error messages when no recipient address is found.

These changes collectively enhance the robustness and flexibility of the system's notification and alerting mechanisms.

@caffeinated92 caffeinated92 merged commit b4f532c into develop Apr 28, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant