I made first look to Apache Arrow Java sources.
I found wrong implementation for DefaultVectorComparators.LongComparator
I suppose that other comparators can be wrong too.
Simple test:
long l1=Long.MIN_VALUE +1L;
long l2=Long.MAX_VALUE;
System.out.println("Arrow: " + Long.signum(l1 - l2));
System.out.println("Java : " + Long.compare(l1, l2));
Result:
Arrow: 1
Java : -1
I think that there should be added tests for corner cases. And I suggest to
replace arrow implementation with Long.compare, Integer.compare...
that provides correct results.
Thank you
Martin
PS I have no access to JIRA to report this issue.