After a change in the unienv.bat related to the JDBC driver used to connect to the External Database (MS SQL on this case), the UVMS fails to start with the following error in uvserver.log:
|ERROR| main | org.hibernate.engine.jdbc.spi.SqlExceptionHelper | Cannot load JDBC driver class 'com.orsyp.driver.FakeSQLServerDriver'
On unistart.log you observe a similar error related to the JDBC driver:
java.security.PrivilegedActionException: com.orsyp.InitializationException: Cannot initialize UVMSCaused by: com.orsyp.InitializationException: Cannot initialize UVMSCaused by: com.orsyp.InitializationException: A problem occurred while initializing the server.Caused by: com.orsyp.InitializationException: Failed initializing server: Could not open JPA EntityManager for transaction; nested exception is org.hibernate.exception.GenericJDBCException: Unable to acquire JDBC ConnectionCaused by: org.springframework.transaction.CannotCreateTransactionException: Could not open JPA EntityManager for transaction; nested exception is org.hibernate.exception.GenericJDBCException: Unable to acquire JDBC ConnectionCaused by: org.hibernate.exception.GenericJDBCException: Unable to acquire JDBC ConnectionCaused by: org.apache.commons.dbcp.SQLNestedException: Cannot load JDBC driver class 'com.orsyp.driver.FakeSQLServerDriver'Caused by: java.lang.NoClassDefFoundError: Could not initialize class com.orsyp.driver.FakeSQLServerDriver
UVMS 7.x with External Database on Windows
Wrong value for the variable JDBC_JAR_PATH_ORSYP in the file (<uvms_folder>\data\unienv.bat) as it was pointing to a folder instead of a jar file as seen below:
set JDBC_JAR_PATH_ORSYP="C:\PROGRA~1\MICROS~2"
Update the value for the variable JDBC_JAR_PATH_ORSYP in the file (<uvms_folder>\data\unienv.bat) so that it points to the jar file that corresponds to your Java version, like for example:
set JDBC_JAR_PATH_ORSYP="C:\Program Files\Microsoft SQL Server\mssql-jdbc-9.2.0.jre8.jar"
Then start UVMS again, this time it will start correctly.