summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorSimon Rettberg2018-12-12 11:50:53 +0100
committerSimon Rettberg2018-12-12 11:50:53 +0100
commit7005515576de5f38138d01e047d022c7522ed5b3 (patch)
tree3a2dd17c724ebff8391c7bcd43040bdd5253cff2 /src
parentadded initial data for operatingsystem, virtualizer and os_x_virt (diff)
downloadmasterserver-7005515576de5f38138d01e047d022c7522ed5b3.tar.gz
masterserver-7005515576de5f38138d01e047d022c7522ed5b3.tar.xz
masterserver-7005515576de5f38138d01e047d022c7522ed5b3.zip
Update MySQL connector to 8.0.13
Diffstat (limited to 'src')
-rw-r--r--src/main/java/org/openslx/imagemaster/db/Database.java13
1 files changed, 10 insertions, 3 deletions
diff --git a/src/main/java/org/openslx/imagemaster/db/Database.java b/src/main/java/org/openslx/imagemaster/db/Database.java
index cdc6fb5..710dea0 100644
--- a/src/main/java/org/openslx/imagemaster/db/Database.java
+++ b/src/main/java/org/openslx/imagemaster/db/Database.java
@@ -76,9 +76,16 @@ public class Database
try {
Class.forName( "com.mysql.cj.jdbc.Driver" ).newInstance();
- } catch ( InstantiationException | IllegalAccessException | ClassNotFoundException e ) {
- LOGGER.fatal( "Cannot get mysql JDBC driver!", e );
- System.exit( 1 );
+ } catch ( Exception e1 ) {
+ LOGGER.warn( "Cannot get mysql JDBC driver (new path)", e1 );
+ LOGGER.info( "Trying old path..." );
+ try {
+ Class.forName( "com.mysql.jdbc.Driver" ).newInstance();
+ } catch ( Exception e2 ) {
+ LOGGER.fatal( "Cannot get mysql JDBC driver (old path)", e2 );
+ LOGGER.fatal( "Bailing!" );
+ System.exit( 1 );
+ }
}
}