Skip to content
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

Investigate SessionFactory.doInSession(…) and ReactiveSessionFactory.doInSession(…) [DATACASS-768] #936

Open
spring-projects-issues opened this issue May 19, 2020 · 0 comments
Assignees
Labels
type: enhancement A general enhancement

Comments

@spring-projects-issues
Copy link

Mark Paluch opened DATACASS-768 and commented

Spring Data's approach uses a CqlSession per keyspace/tenant to achieve multi-tenancy. Keeping multiple sessions is considered an anti-pattern by the driver which should not be used.

A singleton session with keyspace routing capabilities would require the Cassandra V5 protocol as the new version allows association of keyspaces per statement.

The new protocol is not yet available so we should investigate whether we can switch to a callback-pattern to enclose Cassandra calls. Implementations of SessionFactory could go ahead and issue a setKeyspace call before and after the execution.

We also need to consider how this could work in an asynchronous scenario


No further details from DATACASS-768

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: enhancement A general enhancement
Projects
None yet
Development

No branches or pull requests

2 participants