[release/6.x] Respond with available snapshot rather than Bad Request error
#7415
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.
Partial cherry-pick from #7373 to resolve #7409.
#7373 changed behaviour on both the client and server side to support the new flow. The problem is that the client may now send requests that cause an old (6.x) server to respond with a
400 Bad Request, and it seems downstream of that we occasionally fail the LTS test.This cherry-picks the server-side change, so it will accept these request and respond with the sub-range.
We could revert this behaviour change on
main, and then try another multi-step migration. I think it'd still need a change on 6.x to match up. We could also change the behaviour onmain/7.xto fallback when we receive a400and interop nicely with a known-old node. I think that's a huge amount of extra code and complication, and not worth it. So this is my proposed fix.