rkhachatryan commented on a change in pull request #15720:
URL: https://github.com/apache/flink/pull/15720#discussion_r620432260
##########
File path: docs/content/docs/connectors/datastream/jdbc.md
##########
@@ -167,15 +177,24 @@ env
ps.setDouble(4, t.price);
ps.setInt(5, t.qty);
},
- JdbcExecutionOptions.builder().build(),
+ JdbcExecutionOptions.builder()
+ .withMaxRetries(0)
+ .build(),
JdbcExactlyOnceOptions.defaults(),
() -> {
// create a driver-specific XA DataSource
+ // The following example is for derby
EmbeddedXADataSource ds = new EmbeddedXADataSource();
ds.setDatabaseName("my_db");
return ds;
});
env.execute();
```
+Postgres XADataSource Example:
+```java
+PGXADataSource pgxaDataSource = new PGXADataSource();
+pgxaDataSource.setUrl(
+"jdbc:postgresql://localhost:5432/postgres");
Review comment:
I think users will likely need this too:
```
pgxaDataSource.setUser(username);
pgxaDataSource.setPassword(password);
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]