URI uri = new URI(databaseURL);
String jdbcUrl =
String.format(
"jdbc:%s://%s:%s/%s",
"postgresql", uri.getHost(), uri.getPort(), uri.getPath().substring(1));
Properties props = new Properties();
String[] credentials = uri.getUserInfo().split(":");
props.setProperty("user", credentials[0]);
props.setProperty("password", credentials[1]);There are probably myriad ways to solve this with Maven, but one option is to keep a single properties file in your /src/main/resources path, load it using the properties-maven-plugin (an example can be seen in the jOOQ-Spring example), and then compose URLs using the individual parts, e.g. jOOQ and Flyway:
<url>jdbc:postgresql://${db.host}:${db.port}/${db.database}</url>
<user>${db.username}</user>
<password>${db.password}</password>Heroku:
<database_url>postgres://${db.username}:${db.password}@${db.host}:${db.port}/${db.databa--
You received this message because you are subscribed to the Google Groups "jOOQ User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jooq-user+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Thanks that will work as long as I can read it from the ENVIRONMENT
and nothing goes into the src/main/resources directory that has any database information. But if it's just patterns in there that could work. I'll take a look at the examples.