You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@hbase.apache.org by Wenjun Yan <my...@gmail.com> on 2016/04/11 09:39:45 UTC

why Get#setMaxVersions throw an IOException

Hi, there!

I'm using hbase-client 1.1.2 and I found that Get#setMaxVersions would
throw an IOException if the the parameter maxVersions is less than 0. I'm
just wondering what's the point in throwing an IOException instead of
IllegalArgumentException.

https://github.com/apache/hbase/blob/master/hbase-client/src/main/java/org/apache/hadoop/hbase/client/Get.java#L246

while Scan#setMaxVersions doesn't throw an exception at all.

https://github.com/apache/hbase/blob/master/hbase-client/src/main/java/org/apache/hadoop/hbase/client/Scan.java#L476-L479

Thanks.
Yan