aws-samples / aws-health-aware

AHA is an incident management & communication framework to provide real-time alert customers when there are active AWS event(s). For customers with AWS Organizations, customers can get aggregated active account level events of all the accounts in the Organization. Customers not using AWS Organizations still benefit alerting at the account level.
MIT No Attribution
348 stars 143 forks source link

Moving get_account_name call to account loop #73

Closed gdougaws closed 8 months ago

gdougaws commented 11 months ago

Issue #72

Description of changes: Moved the call to get_account_name from the event_entities loop to the affected_accounts loop to reduce the number of calls to get the account name when in Org Mode to a single call per account instead of a call per entity/resource.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

gdougaws commented 11 months ago

Updated PR to include if statement to skip the get_account_name call if the event contains more than 100 accounts.

andrewcr7 commented 8 months ago

Closing as we resolved in a separate PR https://github.com/aws-samples/aws-health-aware/pull/78