Open
Conversation
added 3 commits
January 19, 2018 15:41
Prior to this commit the combination of: * Order reuse * Authz reuse within orders * Orders not being set invalid on a failed challenge/authz Meant that if a user created an order, failed (or deactivated) one of the associated authzs, and then tried to create another order for the same names they would get back the original order with the failed/deactivated authzs. Oops! This commit addresses this problem in three main ways: 1. Pending authz reuse within orders is removed. There's no advantage to reusing one pending authz across multiple orders when we have reuse at the order level and it complicates invalidating an order when a pending authz is finalized to invalid. 2. When an authz is finalized to an invalid state the SA now tries to find an associated order (if any) using the `orderToAuthz` join table. If an order is associated with the authz being finalized as invalid then the order is also updated to be invalid. 3. When NewOrder looks for an order to reuse it only reuses the order if the status is pending. The combination of the above means that calling NewOrder, failing (or deactivating an authz) and then calling NewOrder again will not result in the same "stuck" order being returned for the second call. The associated integration test was written ahead of the fixes and verifies that the change has the intended affect. Prior to the fixes it failed in the same manner as reported by users of the V2 staging API.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.