fapaul commented on code in PR #18604:
URL: https://github.com/apache/flink/pull/18604#discussion_r843829654
##########
flink-connectors/flink-connector-jdbc/src/main/java/org/apache/flink/connector/jdbc/internal/converter/PostgresRowConverter.java:
##########
@@ -91,7 +91,10 @@ private JdbcDeserializationConverter
createPostgresArrayConverter(ArrayType arra
final Object[] array = (Object[])
Array.newInstance(elementClass, in.length);
for (int i = 0; i < in.length; i++) {
array[i] =
- elementConverter.deserialize(((PGobject)
in[i]).getValue().getBytes());
+ elementConverter.deserialize(
+ in[i] instanceof byte[]
+ ? in[i]
+ : ((PGobject)
in[i]).getValue().getBytes());
Review Comment:
Thanks for the thorough explanation and good catch. Since it looks like a
new functionality, I would expect to also have a dedicated test case for
`byte[]`. WDYT?
--
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]