hbase-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Guanghao Zhang (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HBASE-17312) [JDK8] Use default method in XXXObserver
Date Fri, 10 Feb 2017 06:37:41 GMT

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

Guanghao Zhang commented on HBASE-17312:
----------------------------------------

Copy the discussion from HBASE-11392.

Andrew Purtell added a comment - 13/Dec/16 20:05
All new master admin APIs need coprocessor hook support and support in the AccessController
for access control.
  
zghaobac Guanghao Zhang added a comment - 14/Dec/16 01:26
Thanks for pointed out this. I thought the new master replication admin APIs will only be
added to 2.0 which only support java 8. So for compatibility issue, the new APIs in coprocessor
should use default method?

 apurtell Andrew Purtell added a comment - 14/Dec/16 02:16
Current implementation defines interfaces (XXXObserver) and then abstract base classes (BaseXXXObserver)
meant for consumption by implementors. We can change this to default methods but if so I think
we should do it for all or none to make it less confusing.
  
zghaobac Guanghao Zhang added a comment - 14/Dec/16 02:41
bq. but if so I think we should do it for all or none to make it less confusing.
Aggred. Open a new jdk8 issue HBASE-17312 for this.

> [JDK8] Use default method in XXXObserver
> ----------------------------------------
>
>                 Key: HBASE-17312
>                 URL: https://issues.apache.org/jira/browse/HBASE-17312
>             Project: HBase
>          Issue Type: Sub-task
>          Components: Coprocessors
>    Affects Versions: 2.0.0
>            Reporter: Guanghao Zhang
>            Assignee: Guanghao Zhang
>
> Use default method in MasterObserver, RegionObserver, RegionServerObserver and WALObserver.
And mark the BaseRegionObserver, BaseMasterAndRegionObserver, BaseRegionServerObserver and
BaseWALObserver. User can implement the interface directly and will not break compatibility
when add new default methods.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Mime
View raw message