-
Notifications
You must be signed in to change notification settings - Fork 204
Ele 4028 messaging integ #1799
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
Ele 4028 messaging integ #1799
Conversation
|
👋 @MikaKerman |
| self, | ||
| destination: DestinationType, | ||
| message_context: MessageContextType, | ||
| message_body: MessageBody, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the names are a little confusing, since the parameters regard different messages, maybe message_context and reply_body
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
how about just body?
| channel: Optional[str] = None | ||
|
|
||
|
|
||
| def send_adaptive_card(webhook_url: str, card: dict) -> requests.Response: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
all of the comments in this method are redundant
| @@ -0,0 +1,84 @@ | |||
| from datetime import datetime | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this whole file is duplicated
- Moved alert grouping logic from integration to data monitoring alerts - Added support for grouping all alerts when threshold is met - Updated alert sending to handle individual alerts instead of bulk sending - Simplified alert processing and added type hints - Deprecated bulk alert sending methods in base integration
- Created base abstract class for messaging integrations with generic support - Implemented `BaseMessagingIntegration` with abstract methods for sending messages and checking reply support - Added custom exceptions for messaging integration errors - Introduced `MessageSendResult` generic model to track message sending context
044b0c0 to
53b5c68
Compare
- Implemented `TeamsWebhookMessagingIntegration` for sending messages to Microsoft Teams - Created support for sending Adaptive Cards via webhook - Added error handling and logging for webhook message sending - Implemented method to check reply support (not supported for Teams)
- Created detailed documentation explaining the new messaging integration architecture - Described key components like `BaseMessagingIntegration` and migration strategy - Outlined implementation guidelines for new messaging platform integrations - Highlighted current and future support for messaging platforms
- Updated `DataMonitoringAlerts` to support both legacy and new messaging integrations - Implemented dual-path alert sending logic for BaseIntegration and BaseMessagingIntegration - Added `_send_message()` method to handle new messaging integration message sending - Created `get_health_check_message()` for test message support in new integrations - Updated `Integrations` class to support gradual migration to new messaging system - Added destination resolution method for messaging integrations
53b5c68 to
e197ac6
Compare
- Updated parameter name from `message_body` to `body` in base messaging integration methods - Synchronized parameter naming across `BaseMessagingIntegration`, `TeamsWebhookMessagingIntegration`, and `DataMonitoringAlerts` - Simplified method signatures and improved consistency in messaging integration code - Updated README example to reflect new parameter naming convention
null