deephaven / deephaven-core

Deephaven Community Core
Other
256 stars 80 forks source link

cpp-client hangs or fails when handling unexpected VARBINARY type #6287

Open devinrsmith opened 2 weeks ago

devinrsmith commented 2 weeks ago

The cpp-client hangs or fails when handling unexpected VARBINARY type.

For example, applying the patch

index b11cc5f2a0..5d21609bba 100755
--- a/extensions/barrage/src/main/java/io/deephaven/extensions/barrage/util/BarrageUtil.java
+++ b/extensions/barrage/src/main/java/io/deephaven/extensions/barrage/util/BarrageUtil.java
@@ -736,6 +736,9 @@ public class BarrageUtil {
                 return Types.MinorType.FLOAT8.getType();
             case Object:
                 if (type.isArray()) {
+                    if (type == byte[].class) {
+                        return Types.MinorType.VARBINARY.getType();
+                    }
                     return Types.MinorType.LIST.getType();
                 }
                 if (type == LocalDate.class) {

and running

./gradlew cpp-client:check

will demonstrate the issue.

devinrsmith commented 2 weeks ago

This is mainly about fixing the "why does it hang", and/or improving the error messages.

It may also be reasonable to consider cpp client support for arrow::BinaryArray