[
https://issues.apache.org/jira/browse/HBASE-9164?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13740164#comment-13740164
]
Jonathan Hsieh commented on HBASE-9164:
---------------------------------------
Ah, ok, there are 6 instances left
{code}
jon@swoop:~/proj/hbase-trunk$ grep -r "\? extends Cell" . | grep "\.java:"
./hbase-server/src/test/java/org/apache/hadoop/hbase/protobuf/TestReplicationProtobuf.java:
List<List<? extends Cell>> all = new ArrayList<List<? extends Cell>>();
./hbase-server/src/main/java/org/apache/hadoop/hbase/protobuf/ReplicationProtbufUtil.java:
List<List<? extends Cell>> allkvs = new ArrayList<List<? extends
Cell>>(entries.length);
./hbase-server/src/main/java/org/apache/hadoop/hbase/protobuf/ReplicationProtbufUtil.java:
static CellScanner getCellScanner(final List<List<? extends Cell>> cells,
final int size) {
./hbase-server/src/main/java/org/apache/hadoop/hbase/protobuf/ReplicationProtbufUtil.java:
private final Iterator<List<? extends Cell>> entries = cells.iterator();
./hbase-server/src/main/java/org/apache/hadoop/hbase/protobuf/ReplicationProtbufUtil.java:
private Iterator<? extends Cell> currentIterator = null;
./hbase-client/src/main/java/org/apache/hadoop/hbase/client/Result.java:
public Result(List<? extends Cell> kvs) {
{code}
* 1 in test (ok to keep)
* 4 in replication (updated to be marked InterfaceeAudience.Private
* 1 remains exposed (Result constructor).
I'm going to do one more iteration to try to get rid of the expose <? extends
Cell> and possibly cleanup code to remove cruft.
> Convert List<? extends Cell> anti pattern to List<Cell> pattern.
> ----------------------------------------------------------------
>
> Key: HBASE-9164
> URL: https://issues.apache.org/jira/browse/HBASE-9164
> Project: HBase
> Issue Type: Bug
> Components: Client
> Affects Versions: 0.95.1
> Reporter: Jonathan Hsieh
> Assignee: Jonathan Hsieh
> Priority: Blocker
> Fix For: 0.95.2
>
> Attachments: hbase-9164.patch
>
>
> As described in HBASE-9142, using List<? extends Cell> is an anti pattern
> that adds unnecessary typing and casting clutter to the code base. It would
> be best to remove this before we release 0.95.2 or 0.96.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira