mirror of
https://github.com/scm-manager/scm-manager.git
synced 2026-05-07 11:16:59 +02:00
added default configuration for orientdb
This commit is contained in:
@@ -55,6 +55,18 @@ import javax.xml.bind.JAXB;
|
||||
public class ConnectionProvider implements Provider<ODatabaseDocumentTx>
|
||||
{
|
||||
|
||||
/** Field description */
|
||||
public static final String DEFAULT_DB_DIRECTORY = "db";
|
||||
|
||||
/** Field description */
|
||||
public static final String DEFAULT_DB_SHEME = "local:";
|
||||
|
||||
/** Field description */
|
||||
public static final String DEFAULT_PASSWORD = "admin";
|
||||
|
||||
/** Field description */
|
||||
public static final String DEFAULT_USERNAME = "admin";
|
||||
|
||||
/** Field description */
|
||||
public static final String PATH =
|
||||
"config".concat(File.separator).concat("orientdb.xml");
|
||||
@@ -76,7 +88,13 @@ public class ConnectionProvider implements Provider<ODatabaseDocumentTx>
|
||||
else
|
||||
{
|
||||
|
||||
// TODO
|
||||
// create default connection configuration
|
||||
File directory = new File(SCMContext.getContext().getBaseDirectory(),
|
||||
DEFAULT_DB_DIRECTORY);
|
||||
String url = DEFAULT_DB_SHEME.concat(directory.getAbsolutePath());
|
||||
|
||||
init(new ConnectionConfiguration(url, DEFAULT_USERNAME,
|
||||
DEFAULT_PASSWORD));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user