digitalfondue / lavagna

Lavagna: issue tracker/project management tool
http://lavagna.io
GNU General Public License v3.0
636 stars 110 forks source link

Fail to start due to instantiation failure #158

Closed KeruruBruce closed 3 years ago

KeruruBruce commented 3 years ago

Hi, I have tried using mem db HSQLDB and it works well. However, when i switch it to mySQL (mySQL 5.7), the application shows a few exceptions when launched. The application can access mySQL because some tables and functions with the LA prefix are generated in the default database lavagna after the execution; however, it seems to fail at certain point. In the end, the web page only shows HTTP ERROR 503 Service Unavailable.

The exceptions would be like the following:

Is it possible to skip the migration by executing stand-alone sql script? Or is there other way to fix it possibly.

Thank you.

KeruruBruce commented 3 years ago

btw, I remove and recreate the default database lavagna every time to not cause the duplicate issue.

syjer commented 3 years ago

hi @KeruruBruce

well, the message "Migration of schema lavagna to version 1 - INITIAL VERSION failed! Please restore backups and roll back database and code!" mean something has gone wrong during the first install of the database on mysql. Maybe there is an incompatibility in the sql script with your specific mysql version.

Is it possible to skip the migration by executing stand-alone sql script? Or is there other way to fix it possibly.

yes, you can define the following property: datasource.disable.migration=true , then you must execute the following scripts: https://github.com/digitalfondue/lavagna/tree/master/src/main/resources/io/lavagna/db/MYSQL from V1 .. to V25 but it's not something that I would advise to do.

Instead it would be better to debug the issue in why the sql migration is failing.

KeruruBruce commented 3 years ago

Hi @syjer,

Thank you. I have tried different mysql version. The migration works now with mysql 8.0.