Add support for SAP MaxDB

SAP MaxDB (http://maxdb.sap.com/) is now supported as a database.

Depends-On: I9385bafe481152ce0c1471f2a7f89b1db5abac80
Change-Id: Iae2ad25a3db3a1069b80cf5733c92882da86e404
This commit is contained in:
Stefan Lay
2013-04-18 16:21:42 +02:00
committed by Adrian Görler
parent 2fc609be42
commit 3e8dee2861
7 changed files with 281 additions and 3 deletions

View File

@@ -26,5 +26,12 @@ public class DataSourceModule extends AbstractModule {
bind(DataSourceType.class).annotatedWith(Names.named("mysql")).to(MySql.class);
bind(DataSourceType.class).annotatedWith(Names.named("oracle")).to(Oracle.class);
bind(DataSourceType.class).annotatedWith(Names.named("postgresql")).to(PostgreSQL.class);
/*
* DatabaseMetaData.getDatabaseProductName() returns "sap db" for MaxDB.
* For auto-detection of the DB type (com.google.gerrit.pgm.util.SiteProgram#getDbType)
* we have to map "sap db" additionally to "maxdb", which is used for explicit configuration.
*/
bind(DataSourceType.class).annotatedWith(Names.named("maxdb")).to(MaxDb.class);
bind(DataSourceType.class).annotatedWith(Names.named("sap db")).to(MaxDb.class);
}
}