Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

[petclinic-grails] Use PostgreSQL for production & Cloud Foundry.

  • Loading branch information...
commit 53fabaced5b8bda066912f9f8154573429992c90 1 parent 928f6b8
Peter Ledbrook pledbrook authored
Showing with 24 additions and 23 deletions.
  1. +24 −23 petclinic-grails/grails-app/conf/DataSource.groovy
47 petclinic-grails/grails-app/conf/DataSource.groovy
View
@@ -1,8 +1,8 @@
dataSource {
- pooled = true
- driverClassName = "org.hsqldb.jdbcDriver"
- username = "sa"
- password = ""
+ pooled = true
+ driverClassName = "org.hsqldb.jdbcDriver"
+ username = "sa"
+ password = ""
}
hibernate {
cache.use_second_level_cache=true
@@ -11,22 +11,23 @@ hibernate {
}
// environment specific settings
environments {
- development {
- dataSource {
- dbCreate = "create-drop" // one of 'create', 'create-drop','update'
- url = "jdbc:hsqldb:mem:devDB"
- }
- }
- test {
- dataSource {
- dbCreate = "update"
- url = "jdbc:hsqldb:mem:testDb"
- }
- }
- production {
- dataSource {
- dbCreate = "update"
- url = "jdbc:hsqldb:file:prodDb;shutdown=true"
- }
- }
-}
+ development {
+ dataSource {
+ dbCreate = "create-drop" // one of 'create', 'create-drop','update'
+ url = "jdbc:hsqldb:mem:devDB"
+ }
+ }
+ test {
+ dataSource {
+ dbCreate = "update"
+ url = "jdbc:hsqldb:mem:testDb"
+ }
+ }
+ production {
+ dataSource {
+ dbCreate = "update"
+ driverClassName = "org.postgresql.Driver"
+ url = "jdbc:postgresql://localhost:5432/petclinic"
+ }
+ }
+}
Please sign in to comment.
Something went wrong with that request. Please try again.