[jira] [Updated] (HBASE-22461) A "NullPointerException" could be thrown; "Result" is nullable
[ https://issues.apache.org/jira/browse/HBASE-22461?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Duo Zhang updated HBASE-22461: -- Resolution: Won't Fix Status: Resolved (was: Patch Available) Resolve. Feel free to reopen if you think this is still a problem which needs to be fixed. [~hapihu]. Thanks. > A "NullPointerException" could be thrown; "Result" is nullable > -- > > Key: HBASE-22461 > URL: https://issues.apache.org/jira/browse/HBASE-22461 > Project: HBase > Issue Type: Bug > Components: Client >Affects Versions: 2.1.4 >Reporter: wuguihu >Priority: Major > Attachments: HBASE-22461.patch > > > In hbase-client model the class > "org.apache.hadoop.hbase.MetaTableAccessor"'s method getRegionInfo(final > Result r, byte [] qualifier),A "NullPointerException" could be thrown; "r" is > nullable here. > > {code:java} > @Nullable > private static RegionInfo getRegionInfo(final Result r, byte [] qualifier) { > Cell cell = r.getColumnLatestCell(getCatalogFamily(), qualifier); > if (cell == null) return null; > return RegionInfo.parseFromOrNull(cell.getValueArray(), > cell.getValueOffset(), cell.getValueLength()); > } > {code} > -- This message was sent by Atlassian Jira (v8.20.10#820010)
[jira] [Updated] (HBASE-22461) A "NullPointerException" could be thrown; "Result" is nullable
[ https://issues.apache.org/jira/browse/HBASE-22461?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Duo Zhang updated HBASE-22461: -- Fix Version/s: (was: 3.0.0-beta-1) > A "NullPointerException" could be thrown; "Result" is nullable > -- > > Key: HBASE-22461 > URL: https://issues.apache.org/jira/browse/HBASE-22461 > Project: HBase > Issue Type: Bug > Components: Client >Affects Versions: 2.1.4 >Reporter: wuguihu >Priority: Major > Attachments: HBASE-22461.patch > > > In hbase-client model the class > "org.apache.hadoop.hbase.MetaTableAccessor"'s method getRegionInfo(final > Result r, byte [] qualifier),A "NullPointerException" could be thrown; "r" is > nullable here. > > {code:java} > @Nullable > private static RegionInfo getRegionInfo(final Result r, byte [] qualifier) { > Cell cell = r.getColumnLatestCell(getCatalogFamily(), qualifier); > if (cell == null) return null; > return RegionInfo.parseFromOrNull(cell.getValueArray(), > cell.getValueOffset(), cell.getValueLength()); > } > {code} > -- This message was sent by Atlassian Jira (v8.20.10#820010)
[jira] [Updated] (HBASE-22461) A "NullPointerException" could be thrown; "Result" is nullable
[ https://issues.apache.org/jira/browse/HBASE-22461?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] wuguihu updated HBASE-22461: Attachment: HBASE-22461.patch Status: Patch Available (was: Open) > A "NullPointerException" could be thrown; "Result" is nullable > -- > > Key: HBASE-22461 > URL: https://issues.apache.org/jira/browse/HBASE-22461 > Project: HBase > Issue Type: Bug > Components: Client >Affects Versions: 2.1.4 >Reporter: wuguihu >Priority: Major > Fix For: 3.0.0 > > Attachments: HBASE-22461.patch > > > In hbase-client model the class > "org.apache.hadoop.hbase.MetaTableAccessor"'s method getRegionInfo(final > Result r, byte [] qualifier),A "NullPointerException" could be thrown; "r" is > nullable here. > > {code:java} > @Nullable > private static RegionInfo getRegionInfo(final Result r, byte [] qualifier) { > Cell cell = r.getColumnLatestCell(getCatalogFamily(), qualifier); > if (cell == null) return null; > return RegionInfo.parseFromOrNull(cell.getValueArray(), > cell.getValueOffset(), cell.getValueLength()); > } > {code} > -- This message was sent by Atlassian JIRA (v7.6.3#76005)