Closed ll4strw closed 4 weeks ago
@ll4strw I have updated the documentation in this PR https://github.com/rspace-os/rspace-web/pull/86 to explain an additional deployment property required to use a different database name.
In your case above, you would need to add (in addition to the existing params) -Djdbc.db=rspace_vanilla
.
Let me know if you have any issues. More info here: https://github.com/rspace-os/rspace-web/blob/main/DevDocs/DeveloperNotes/GettingStarted/GettingStarted.md#set-deployment-properties-through-command-line
@rs-fraser I have tried the following with rspace v2.0.0
mvn clean compile
mvn clean jetty:run -Denvironment=drop-recreate-db -DRS.devlogLevel=INFO -Dspring.profiles.active=run -Dliquibase.context=dev-test -DgenerateReactDist -Dlog4j2.configurationFile=log4j2-dev.xml -Djdbc.url=jdbc:mysql://localhost:3306/rspace_vanilla -Djdbc.db=rspace_vanilla
but I still get a bunch of errors like the ones below
ERROR] HHH000389: Unsuccessful: alter table AppConfigElement drop foreign key FK_da27586fw25ixb3nchld54abj
[ERROR] Table 'rspace.AppConfigElement' doesn't exist
[ERROR] HHH000389: Unsuccessful: alter table AppConfigElement drop foreign key FK_aln55rabki06r7hr7r8fmbwvp
[ERROR] Table 'rspace.AppConfigElement' doesn't exist
[ERROR] HHH000389: Unsuccessful: alter table AppConfigElementDescriptor drop foreign key FK_s70jodrxnueplu21nv7x0cxcc
and finally the process stops with
com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Table 'rspace_vanilla.roles' doesn't exist
Must I use the latest version of rspace?
@ll4strw apologies, there's an additional param also required -Djdbc.db.maven=rspace_vanilla
which should work for you. I've update the docs as well.
I'll create an internal ticket too to see if we can simplify these params as we are repeating information and it's quite confusing.
I am instructing RSpace v2.0.0 to use a different database than the default
rspace
by launching it with jetty usingI would expect from option
-Djdbc.url=jdbc:mysql://localhost:3306/rspace_vanilla
that an existing database namedrspace
would be left untouched, instead it is dropped and recreated where as the new databaserspace_vanilla
ends up containing only the following tablesEventually the building and launch process fails with error
Are perhaps options
-Denvironment=drop-recreate-db
and-Djdbc.url=jdbc:mysql://localhost:3306/rspace_vanilla
incompatible? Or is their appearance order important? Thanks.