-
Notifications
You must be signed in to change notification settings - Fork 0
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
Handling of PartnerIncidentIds #6
Comments
PartnerIncidentIds are unique values per partnerId and they are unique as long as the incident exists (so, in practical terms: forever). In my opinion, IDs should serve as identifiers of Incidents - ergo actual tickets, but I do see your usecase. I don't see why a partnerIncidentId should not be "freed-up" when an incident is closed. Let me try and rewrite the validation to allow for partnerIncidentIds to be reused as long as there are no non-closed incidents with that id. I'll get back to you shortly. |
That was easier than anticipated - partnerIncidentId is now freed-up for reuse once an incident is closed. |
Is the partnerIncidentId no longer free'd or is query not reporting correct data? |
You assume correctly that the 404 to the GET indicates the ID is freed up. I cannot recreate your issue. - which leads me to believe an actual race condition may be at play here. Did you encounter the issue since then? |
How does MyIT handle PartnerIncidentIds, are they treated as unique values forever and can never be reused or are they like a key used to deduplicate against and limited to active period of the associated ticket?
Maybe some background to illustrate where I come from:
When a Job experiences errors I take data that distinctly describes the situation (involved client, involved instances, error code) and create a hash and uuid of that to be used as PartnerIncidentId.
That way if a subsequent Job fails with the same conditions i get the same uuid and can update the incident associated with that PartnerIncidentId and not accidentally create dozens of incidents for the same error condition.
That works fine as long as the Incident remains active.
Question is, what happens when the original Issue is closed? When I look up the PartnerIncidentId generated for the condition I probably get a incident back with state 6 or 7, implying that I should create a new Incident. Now when I go and create a new Incident with that same PartnerIncidentId again, would it treat it as a new cycle/instantiation of the error condition and return a new IncidentId or would it throw 409 due to the ID already existing?
When I have to create a PartnerIncidentId that is truly unique and never repeats, how is the indented process to figure out whether or not that ID would create a Duplicate Incident? in sense of content, not IDs.
Please consider intention to be stateless, aka not keeping records on our end which incidents we opened and not wanting to regularly check and update their state in our shadow-records.
The text was updated successfully, but these errors were encountered: