HHH-15755: Let OracleDialect detect if running on Autonomous database
This commit is contained in:
parent
2509b74201
commit
19bc9a432b
|
@ -11,6 +11,7 @@ import org.apache.tools.ant.filters.ReplaceTokens
|
||||||
ext {
|
ext {
|
||||||
db = project.hasProperty('db') ? project.getProperty('db') : 'h2'
|
db = project.hasProperty('db') ? project.getProperty('db') : 'h2'
|
||||||
dbHost = System.getProperty( 'dbHost', 'localhost' )
|
dbHost = System.getProperty( 'dbHost', 'localhost' )
|
||||||
|
dbService = System.getProperty( 'dbService', '' )
|
||||||
dbBundle = [
|
dbBundle = [
|
||||||
h2 : [
|
h2 : [
|
||||||
'db.dialect' : 'org.hibernate.dialect.H2Dialect',
|
'db.dialect' : 'org.hibernate.dialect.H2Dialect',
|
||||||
|
@ -136,6 +137,18 @@ ext {
|
||||||
'jdbc.url' : 'jdbc:oracle:thin:@' + dbHost + ':1521:XE',
|
'jdbc.url' : 'jdbc:oracle:thin:@' + dbHost + ':1521:XE',
|
||||||
'connection.init_sql' : ''
|
'connection.init_sql' : ''
|
||||||
],
|
],
|
||||||
|
oracle_cloud_autonomous_tls : [
|
||||||
|
'db.dialect' : 'org.hibernate.dialect.OracleDialect',
|
||||||
|
'jdbc.driver': 'oracle.jdbc.OracleDriver',
|
||||||
|
'jdbc.user' : 'hibernate_orm_test',
|
||||||
|
'jdbc.pass' : 'Oracle_19_Password',
|
||||||
|
// Requires dbHost (pointing to the right cloud region) AND dbService (unique database name).
|
||||||
|
//
|
||||||
|
// To avoid hibernate-spatial tests failure, JVM must be enabled as stated in documentation:
|
||||||
|
// https://docs.oracle.com/en/cloud/paas/autonomous-database/adbsa/autonomous-oracle-java.html
|
||||||
|
'jdbc.url' : 'jdbc:oracle:thin:@(description=(retry_count=20)(retry_delay=3)(address=(protocol=tcps)(port=1521)(host=' + dbHost + '.oraclecloud.com))(connect_data=(service_name=' + dbService + '_low.adb.oraclecloud.com))(security=(ssl_server_dn_match=yes)))',
|
||||||
|
'connection.init_sql' : ''
|
||||||
|
],
|
||||||
mssql : [
|
mssql : [
|
||||||
'db.dialect' : 'org.hibernate.dialect.SQLServerDialect',
|
'db.dialect' : 'org.hibernate.dialect.SQLServerDialect',
|
||||||
'jdbc.driver': 'com.microsoft.sqlserver.jdbc.SQLServerDriver',
|
'jdbc.driver': 'com.microsoft.sqlserver.jdbc.SQLServerDriver',
|
||||||
|
|
Loading…
Reference in New Issue