List of usage examples for io.vertx.pgclient PgPool pool
static PgPool pool(String connectionUri)
From source file:examples.PgClientExamples.java
License:Apache License
public void configureFromUri(Vertx vertx) { // Connection URI String connectionUri = "postgresql://dbuser:secretpassword@database.server.com:3211/mydb"; // Create the pool from the connection URI PgPool pool = PgPool.pool(connectionUri); // Create the connection from the connection URI PgConnection.connect(vertx, connectionUri, res -> { // Handling your connection });//from w w w .j ava2s.co m }