Skip to content

Conversation

@wprzytula
Copy link
Collaborator

It has happened several times that a configuration option (a method) for GenericSessionBuilder was implemented on SessionBuilder only, even though it suited CloudSessionBuilder as well. To protect against such mistakes:

  • all three impl blocks (both specific ones and the generic one) are guarded with comments,
  • impl SessionBuilder block is renamed to impl GenericSessionBuilder<DefaultMode> to highlight that this is a specific implementation only.

Pre-review checklist

  • I have split my patch into logically separate commits.
  • All commit messages clearly explain what they change and why.
  • [ ] I added relevant tests for new features and bug fixes.
  • All commits compile, pass static checks and pass test.
  • PR description sums up the changes and reasons why they should be introduced.
  • [ ] I have provided docstrings for the public items that I want to introduce.
  • [ ] I have adjusted the documentation in ./docs/source/.
  • [ ] I added appropriate Fixes: annotations to PR description.

It has happened several times that a configuration option (a method) for
`GenericSessionBuilder` was implemented on `SessionBuilder` only, even
though it suited `CloudSessionBuilder` as well. To protect against such
mistakes:
- all three `impl` blocks (both specific ones and the generic
one) are guarded with comments,
- `impl SessionBuilder` block is renamed to `impl
  GenericSessionBuilder<DefaultMode>` to highlight that this is a
specific implementation only.
@wprzytula wprzytula requested a review from piodul July 31, 2023 13:42
@piodul piodul merged commit 40aaee6 into scylladb:main Aug 2, 2023
@wprzytula wprzytula deleted the session-builder-where-to-put-methods branch August 2, 2023 06:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants