Details
-
Sub-task
-
Status: Resolved
-
Minor
-
Resolution: Fixed
-
3.0.0
-
None
Description
While working on JDK 11 support, I noticed a lot of new deprecation warnings. 80% of them seem to be from two easily-fixable sources:
- Class.newInstance() is deprecated
- Almost all constructors from primitive wrapper classes like Integer are deprecated
These are easy to fix because there have long been equivalent, better alternatives:
- Just call .getConstructor().newInstance()
- Replace new Integer with Integer.valueOf, etc
The latter has the advantage, for integral types, of not even allocating a new object for small values.
We should just fix these to clean up the build output.