Settin up Grails 3.3.9 with PostgresSQL 12.7

Roberto Riarte

New member
i tried to connect a postgresdatabase in my grails 3.3.9 project; My posgrest server is working, since I can connect and operate on the posgres database from Intelli J 2021 databse, but I can't connect to grails 3.3.9. The password and user are correct but it always throws me this error:


Running application...
2021-07-05 19:06:25.298 ERROR --- [ main] org.postgresql.Driver : Connection error:

org.postgresql.util.PSQLException: El servidor requiere autenticación basada en contraseña, pero no se ha provisto ninguna contraseña.


And this mi Application.yml

hibernate:
cache:
queries: false
use_second_level_cache: false
use_query_cache: false

dataSource:
IkebanaUsuarios:
pooled: true
jmxExport: true
driverClassName: "org.postgresql.Driver"
username: "postgres"
password: "postgres"


environments:
development:
dataSource:
dbCreate: update
url: jdbc:postgresql://localhost:5432/IkebanaERP
test:
dataSource:
dbCreate: update
url: jdbc:postgresql://localhost:5432/IkebanaERP
production:
dataSource:
dbCreate: update
url: jdbc:postgresql://localhost:5432/IkebanaERP
properties:
jmxEnabled: true
initialSize: 5
maxActive: 50
minIdle: 5
maxIdle: 25
maxWait: 10000
maxAge: 600000
timeBetweenEvictionRunsMillis: 5000
minEvictableIdleTimeMillis: 60000
validationQuery: SELECT 1
validationQueryTimeout: 3
validationInterval: 15000
testOnBorrow: true
testWhileIdle: true
testOnReturn: false
jdbcInterceptors: ConnectionState
defaultTransactionIsolation: 2 # TRANSACTION_READ_COMMITTED


and my build.graddle is this

.......
compile "org.grails.plugins:cache"
compile "org.grails.plugins:async"
compile "org.grails.plugins:scaffolding"
compile "org.grails.plugins:events"
compile "org.grails.plugins:hibernate5"
compile "org.hibernate:hibernate-core:5.1.16.Final"
compile "org.grails.plugins:gsp"
console "org.grails:grails-console"
profile "org.grails.profiles:web"
runtime "org.glassfish.web:el-impl:2.1.2-b03"
runtime "com.h2database:h2"
runtime "org.apache.tomcat:tomcat-jdbc"
runtime "com.bertramlabs.plugins:asset-pipeline-grails:2.15.1"

runtime 'org.xerial:sqlite-jdbc:3.6.17'
runtime 'org.postgresql:postgresql:9.4.1208.jre1.8'
runtime 'mysql:mysql-connector-java:5.1.29'
runtime 'org.postgresql:postgresql:42.2.1.jre7'

testCompile "org.grails:grails-gorm-testing-support"
testCompile "org.grails.plugins:geb"
testCompile "org.grails:grails-web-testing-support"
testRuntime "org.seleniumhq.selenium:selenium-htmlunit-driver:2.47.1"
testRuntime "net.sourceforge.htmlunit:htmlunit:2.18"
}


Help please; thanks a lot
 
Top