chamikaramj commented on a change in pull request #15954:
URL: https://github.com/apache/beam/pull/15954#discussion_r753520835
##########
File path:
sdks/java/io/jdbc/src/main/java/org/apache/beam/sdk/io/jdbc/JdbcIO.java
##########
@@ -900,8 +913,32 @@ public void populateDisplayData(DisplayData.Builder
builder) {
return
toBuilder().setOutputParallelization(outputParallelization).build();
}
+ private Coder<OutputT> inferCoder(CoderRegistry registry) {
+ if (getCoder() != null) {
+ return getCoder();
+ } else {
+ RowMapper<OutputT> rowMapper = getRowMapper();
+ TypeDescriptor<OutputT> outputType =
+ TypeDescriptors.extractFromTypeParameters(
+ rowMapper,
+ RowMapper.class,
+ new TypeVariableExtractor<RowMapper<OutputT>, OutputT>() {});
+ try {
+ return registry.getCoder(outputType);
+ } catch (CannotProvideCoderException e) {
Review comment:
LOG the error as well ?
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]