nautobot-app-circuit-maintenance
nautobot-app-circuit-maintenance copied to clipboard
Support omitting the email for a provider if the provider info is contained in the notification
Environment
- Nautobot version: 1.0.0
Proposed Functionality
Make the usage of "Emails for Circuit Maintenance plugin" Custom Field for Provider optional
Use Case
So far, when using CM you need to define a custom email to filter with the FROM and classify them to each provider, assuming that this info is not always properly available from the notification and to narrow done the search.
Even this is still an interesting behaviour in terms of optimization and identification, it could be more relaxed so it could be an optional argument that if not present would behave as:
- ALL the notifications from the source will be taken into account (assuming the impact on the increase of notifications to process)
- Because the notification before being parsed has not any provider identification, when calling the
circuit-maintenance-parserit could use thegenericmethod and try to take the info from the notification if possible, or maybe add some extra metadata, such as the source email address (and match against provider well know addresses) or API urls. - In the case that a
NotificationSourceit's only matching one provider, maybe we could assume that all the notifications are coming from this provider (thinking on a future API integration with an API endpoint), even this could be problematic with other types of integrations based on email boxes.
Related to this, it's awkward as a user that adding a "Emails for Circuit Maintenance Plugin" value to a Provider is not currently sufficient to enable that provider with the plugin, you also have to remember to explicitly add the Provider to a specific NotificationSource. I keep forgetting this step and wondering why the parser job isn't handling emails from a provider that I just added an address for, because I didn't remember to do the second step. Would it be reasonable (even as a configurable option) to make it so that a NotificationSource would automatically attempt to process messages from all provider defined email addresses instead of only a subset that were explicitly opted into by the NotificationSource?
I believe that this issue was mitigated by PR #63