[ 
https://issues.apache.org/jira/browse/HBASE-19046?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16213059#comment-16213059
 ] 

Chia-Ping Tsai commented on HBASE-19046:
----------------------------------------

{code}
        if (this.getCoprocessorHost() != null) {
          this.getCoprocessorHost().postCompactSelection(
              this, ImmutableList.copyOf(compaction.getRequest().getFiles()), 
tracker,
              compaction.getRequest(), user);
        }
{code}
We can pass {{Collections.unmodifiableList()}} now. It doesn't makes a copy of 
all elements from input list.

> RegionObserver#postCompactSelection  Passing an ImmutableList param of PB type
> ------------------------------------------------------------------------------
>
>                 Key: HBASE-19046
>                 URL: https://issues.apache.org/jira/browse/HBASE-19046
>             Project: HBase
>          Issue Type: Sub-task
>          Components: Coprocessors
>            Reporter: Anoop Sam John
>            Assignee: Anoop Sam John
>             Fix For: 2.0.0-alpha-4
>
>         Attachments: HBASE-19046.patch
>
>
> Dont think there is any specific need for passing this PB type.  We can just 
> pass an unmodifiableList list object. Javadoc can say this is an 
> unmodifiableList .  Thats it . No need  that the type itself to be 
> Immutable...



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to