You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@poi.apache.org by bu...@apache.org on 2016/07/05 21:50:58 UTC

[Bug 59804] New: Add annotation for indicating when deprecated features may be removed

https://bz.apache.org/bugzilla/show_bug.cgi?id=59804

            Bug ID: 59804
           Summary: Add annotation for indicating when deprecated features
                    may be removed
           Product: POI
           Version: 3.15-dev
          Hardware: PC
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P2
         Component: POI Overall
          Assignee: dev@poi.apache.org
          Reporter: onealj@apache.org

As part of managing binary and source backwards compatibility, we have
@Internal, @Deprecated (and @deprecated javadoc), annotations.
We usually keep deprecated features around for at least 2 final releases before
removing, but sometimes never get around to removing the deprecated features.
This bug will try to better track the revisit of deprecated elements.

From David North on the dev mailing list [1]:
> * Use the @Deprecated annotation in addition to the JavaDoc tag (which
> is useful for some IDEs anyway)
> * Invent our own @Removal annotation to contain the date/POI version of
> expected removal 
> 
> Then it would be easy to write a functional test which used reflection
> to check all @Deprecated annotated elements had an @Removal too, and to
> tell us when things come up as due to be removed. 

Related: [2] finding the version when a feature was deprecated

[1]
http://apache-poi.1045710.n5.nabble.com/deprecated-handling-reloaded-tp5721071p5721078.html
[2]
http://apache-poi.1045710.n5.nabble.com/Finding-deprecated-methods-td5723416.html

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


[Bug 59804] Add annotation for indicating when deprecated features may be removed

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=59804

--- Comment #6 from Javen O'Neal <on...@apache.org> ---
https://svn.apache.org/viewvc/poi/trunk/src/ooxml/java/org/apache/poi/util/OOXMLLite.java?revision=1782114&view=markup#l200

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


[Bug 59804] Add annotation for indicating when deprecated features may be removed

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=59804

--- Comment #3 from Javen O'Neal <on...@apache.org> ---
Created attachment 34767
  --> https://bz.apache.org/bugzilla/attachment.cgi?id=34767&action=edit
Find @Deprecated and @Removal annotations with reflection

The ClassFinder class in the patch uses non-free code. Do we have something
already in POI test scaffolding that could give us a list of every
org.apache.poi class (bonus points if it can include the o.a.p junit test
code)?

If not, is there an ASL-2.0-licensed version that does something similar?
Otherwise, we'll need to rewrite these couple lines of recursive class finding
via reflection from scratch.

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


[Bug 59804] Add annotation for indicating when deprecated features may be removed

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=59804

--- Comment #1 from Javen O'Neal <on...@apache.org> ---
Added @Removal annotation class in r1751569.

Usage:

/**
 * @since POI 3.6
 * @deprecated POI 3.15 beta 3
 */
@Removal(version="3.17")
public class SomeDeprecatedClassOrMethod() { }

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


[Bug 59804] Add annotation for indicating when deprecated features may be removed

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=59804

PJ Fanning <fa...@yahoo.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |CLOSED
             Status|NEW                         |RESOLVED

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


[Bug 59804] Add annotation for indicating when deprecated features may be removed

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=59804

David North <dt...@corefiling.co.uk> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |dtn-asfbugs@corefiling.co.u
                   |                            |k

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


[Bug 59804] Add annotation for indicating when deprecated features may be removed

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=59804

--- Comment #5 from Javen O'Neal <on...@apache.org> ---
(In reply to Nick Burch from comment #4)
> Doesn't the OOXMLLite code do something much like that only for the schema
> classes?

Probably. The JDK, IDE, and JUnit also find all classes through recursive
reflection, if OOXMLLite doesn't pan out.

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


[Bug 59804] Add annotation for indicating when deprecated features may be removed

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=59804

--- Comment #4 from Nick Burch <ap...@gagravarr.org> ---
Doesn't the OOXMLLite code do something much like that only for the schema
classes?

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


[Bug 59804] Add annotation for indicating when deprecated features may be removed

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=59804

--- Comment #2 from Javen O'Neal <on...@apache.org> ---
Todo: write code that uses reflection to find code that is overdue for removal,
and build this into a unit test.

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org