-
Notifications
You must be signed in to change notification settings - Fork 110
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
session: adjust naming in internal session functions #1156
base: main
Are you sure you want to change the base?
Conversation
The name is more fitting, because this function is generic over CQL request kinds. Query is a name for a specific CQL request. Updated the names of variables, and some types that are directly used by this function. Adjusted the documentation of the function.
|
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.
"Request" is a good word here, but you still use "execute" which is also a CQL command. Maybe "do" / "perform" / "run" are better words than "execute"?
That was one of my doubts. IMO, |
I don't really like "send" because we are not just sending request - we receive the response, we perform speculative execution, retries etc.
Now we have what? I'm not sure what is the proper naming here tbh. Maybe this naming difficulty is a hint that the division of responsibilities between various functions should be different? |
Current division makes sense to me. When it comes to naming, I'll rename all of the functions/closures to |
What do you think about utilizing "speculative fiber" terminology? |
Sounds good. I like it. |
Again, query would suggest that we want to execute a CQL QUERY request. New name also clearly tells the user that provided closure can be potentially executed multiple (based on plan and retry session). Documented the function. Renamed ExecuteQueryContext -> ExecuteRequestContext
8429b53
to
a4e52f2
Compare
Flaky
|
Restarted |
During error refactor, I found it hard to understand what which function does on a request execution path. Three different names were used:
run_query
execute_query
do_query
I renamed them (and all internal structures/traits related to these functions). The
_query
part is very misleading. It would suggest that we want to execute a CQL QUERY request, which is not true - these functions/closures are generic and allow to execute QUERY, EXECUTE and BATCH CQL requests.Kind of related to #713
Pre-review checklist
[ ] I added relevant tests for new features and bug fixes.[ ] I have provided docstrings for the public items that I want to introduce.[ ] I have adjusted the documentation in./docs/source/
.Fixes:
annotations to PR description.