mirror of
https://github.com/ysoftdevs/DependencyCheck.git
synced 2026-03-24 01:51:49 +01:00
updated database schema version so the fix to the lucene index is enforced on clients
Former-commit-id: cc27b0fa533e71b3d6b0a4a3e59b88347fda07d5
This commit is contained in:
@@ -58,7 +58,7 @@ public class CveDB {
|
|||||||
/**
|
/**
|
||||||
* The version of the current DB Schema.
|
* The version of the current DB Schema.
|
||||||
*/
|
*/
|
||||||
public static final String DB_SCHEMA_VERSION = "2.5";
|
public static final String DB_SCHEMA_VERSION = "2.6";
|
||||||
/**
|
/**
|
||||||
* Database connection
|
* Database connection
|
||||||
*/
|
*/
|
||||||
@@ -162,16 +162,6 @@ public class CveDB {
|
|||||||
value = "DMI_EMPTY_DB_PASSWORD",
|
value = "DMI_EMPTY_DB_PASSWORD",
|
||||||
justification = "Yes, I know... Blank password.")
|
justification = "Yes, I know... Blank password.")
|
||||||
public void open() throws IOException, SQLException, DatabaseException, ClassNotFoundException {
|
public void open() throws IOException, SQLException, DatabaseException, ClassNotFoundException {
|
||||||
/*
|
|
||||||
* TODO - make it so we can exteralize the database (lucene index is a problem), could I store it as a blob
|
|
||||||
* and just download it when needed?
|
|
||||||
*/
|
|
||||||
// String dbDriver = Settings.getString(Settings.KEYS.DB_DRIVER);
|
|
||||||
// String dbConnStr = Settings.getString(Settings.KEYS.DB_CONNECTION_STRING);
|
|
||||||
// if (dbDriver != null && dbConnStr != null) {
|
|
||||||
// Class.forName(dbDriver);
|
|
||||||
// conn = DriverManager.getConnection(dbConnStr);
|
|
||||||
// } else { //use the embeded version
|
|
||||||
final String fileName = CveDB.getDataDirectory().getCanonicalPath();
|
final String fileName = CveDB.getDataDirectory().getCanonicalPath();
|
||||||
final File f = new File(fileName, "cve." + DB_SCHEMA_VERSION);
|
final File f = new File(fileName, "cve." + DB_SCHEMA_VERSION);
|
||||||
final File check = new File(f.getAbsolutePath() + ".h2.db");
|
final File check = new File(f.getAbsolutePath() + ".h2.db");
|
||||||
@@ -182,7 +172,6 @@ public class CveDB {
|
|||||||
if (createTables) {
|
if (createTables) {
|
||||||
createTables();
|
createTables();
|
||||||
}
|
}
|
||||||
// }
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Reference in New Issue
Block a user