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

Christopher Tubbs commented on ACCUMULO-1026:
---------------------------------------------

Adam, the best way I know around the problem is to have a separate artifact for 
the client/public API, so that these these are simply not available in the 
first place, if a user is developing against the API jar.

Alternatively, many of these utility functions can either go away, or be 
changed to protected. If necessary, a private inner class, or anonymous class 
can extend the class providing a protected method, so that it isn't visible to 
most users, but can still be made available as needed in other classes.

Automatic warnings are great, but not exposing these things in the classes 
we've identified as public API in the first place is even better. At the very 
least, if it's moved to a place outside of the classes we've identified as the 
public API, that's a reasonable alternative also.
                
> Don't use @Deprecated to mean "Not for Client Use"
> --------------------------------------------------
>
>                 Key: ACCUMULO-1026
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-1026
>             Project: Accumulo
>          Issue Type: Sub-task
>          Components: master, tserver
>            Reporter: Christopher Tubbs
>             Fix For: 1.5.0
>
>
> I understand the convenience of using "@Deprecated" to discourage users from 
> using some bit of code, but I think this is confusing to users, because it 
> doesn't actually mean the functionality is deprecated. This sets a bad 
> precedent, because users may start getting the impression that when we say 
> something is deprecated, we don't really mean it, that we're just keeping 
> something from them.
> Further, using this tag liberally for other purposes, requires us to pollute 
> the code with suppression of warnings, which may hide other potential issues. 
> This wouldn't be an issue if the code were actually deprecated, because we 
> should no longer be using the code ourselves.
> These extra tags got checked in for ACCUMULO-259, and I think they should be 
> cleaned up.
> Some options are:
> # Create another annotation for annotating the public API
> # Create an annotation for annotating "Not For Client Use" when it is 
> inconvenient to remove a method from the API.
> # Use an interface so the method isn't exposed in our public API

--
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

Reply via email to