-
Notifications
You must be signed in to change notification settings - Fork 14
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
Provide an API to get storages initialization state #299
Provide an API to get storages initialization state #299
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Original ticket discusses some possibility to implement simple retries, while this solution provide a manual handle to check the state. Was this design approved by issue authors or product managers? Also, to be honest, I don't think current approach to state check is satisfying (see comments).
f32ad8e
to
3bf2262
Compare
We have discussed this approach with Java connector team and @Totktonada |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you, LGTM!
I'll merge it after #232 . Maybe you'll need to rebase this PR and solve remaining conflict before merge.
Discussed between me, Pavel. S and cartridge-java developers. We agreed that a function that will return status of storages will suit the needs. I can share my vision of the problem. There are a bit different situations:
There are different possible mechanisms that can help in those situations:
Timeouts for queries is the most used mechanish and it allows to overcome small periods of a peer unavailability. We support it, but there are flaws: #95. The also unified error messages for the non-bootstrapped storage case, see PR #296 and PR #297. (It is not great that we propose to match the error message to make programmatic decisions, but errors in crud -- and even in tarantool itself -- requires a redesign and rework IMHO. At least, some revision.) However we still don't offer anything to wait for a potentially long times (over usual query timeout) until the cluster will go into the ready state. It is what we want to solve here. |
58633d9
to
3035210
Compare
3035210
to
428b629
Compare
04f1aba
to
f3aa7c9
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks! The patchset is okay for me in general. However, please, consider several comments and thoughts.
f3aa7c9
to
fcefce9
Compare
fcefce9
to
41f42cc
Compare
dcda205
to
25c6594
Compare
e9c58bf
to
647dba9
Compare
Since there are some GitHub folding, maybe you've missed these unresolved comments so I'll write them down here: |
647dba9
to
f4792ea
Compare
There is an issue with using CRUD functionality if not all storages are up. New function is added to get the information about storages state: initialized or not. So, a user can poll state and wait for storages to be initialized before making CRUD calls. Resolves #229
f4792ea
to
9a730ca
Compare
There is an issue with using CRUD functionality if not all storages are
up. New function is added to get the information about storages
state: initialized or not. So, a user can poll state and wait for
storages to be initialized before making CRUD calls.
Looks like state.lua module is unused. Removed.
Resolves #229