You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Assumes that the user has keyspace create privileges. If the user does NOT have database create privileges, then the evolution will fail and crash the service.
#4
Open
DevoKun opened this issue
Aug 7, 2018
· 2 comments
There needs to be an alternate method to check if the Keyspace exists other than trying to create the keyspace. In my case the keyspace exists, but the service crashes because the user does not have create keyspace permissions.
DevoKun
changed the title
Assumes that the user has database create privileges. If the user does NOT have database create privileges, then the evolution will fail and crash the service.
Assumes that the user has keyspace create privileges. If the user does NOT have database create privileges, then the evolution will fail and crash the service.
Aug 7, 2018
I assume it should be possible to use the list "List permissions" command for this, though I'm not sure if this would be a good idea. The evolution code is pretty generic and unable to guess what might be changed inside this script. It is very well possible that the ops-teams does not want the application-user to create new keyspaces (i.e. keyspaces are administered by some other means/manually).
Or the other way round: The evolution code for standard JDBC/SQL does not check the database permissions either.
play-cassandra-evolutions/src/main/scala/de/leanovate/play/cassandra/evolutions/CassandraEvolutions.scala
Line 222 in 5a99523
The text was updated successfully, but these errors were encountered: