Openbravo Issue Tracking System - Openbravo ERP |
View Issue Details |
|
ID | Project | Category | View Status | Date Submitted | Last Update |
0054452 | Openbravo ERP | A. Platform | public | 2024-01-24 13:37 | 2024-02-09 20:04 |
|
Reporter | shuehner | |
Assigned To | Triage Platform Base | |
Priority | normal | Severity | minor | Reproducibility | have not tried |
Status | closed | Resolution | fixed | |
Platform | | OS | 5 | OS Version | |
Product Version | | |
Target Version | | Fixed in Version | PR24Q2 | |
Merge Request Status | |
Review Assigned To | |
OBNetwork customer | |
Web browser | |
Modules | Core |
Support ticket | |
Regression level | |
Regression date | |
Regression introduced in release | |
Regression introduced by commit | |
Triggers an Emergency Pack | No |
|
Summary | 0054452: Avoid compiler warning about implicit annotation processing by disabling it using -proc:none |
Description | Until Java<21 the java compiler implicitely looked for and ran any annotation processor found on the classpath.
Since Java21 the following warning is shown to inform users about upcoming change.
[javac] Note: Annotation processing is enabled because one or more processors were found
[javac] on the class path. A future release of javac may disable annotation processing
[javac] unless at least one processor is specified by name (-processor), or a search
[javac] path is specified (--processor-path, --processor-module-path), or annotation
[javac] processing is enabled explicitly (-proc:only, -proc:full).
[javac] Use -Xlint:-options to suppress this message.
[javac] Use -proc:none to disable annotation processing.
Upstream intention/recommendation instead is to explicitely specify/configure annotation processing by the build tool.
However a "compatibility option" -proc:full was added to keep using the "old default policy"
|
Steps To Reproduce | Running compile with jdk-21 |
Proposed Solution | Not knowingly needing any annotation processing idea is to explicitely disable it using -proc:none
If usage should show up later it is better to explicitely notice this (i.e. in CI) and then work on properly supporting that.
|
Additional Information | |
Tags | No tags attached. |
Relationships | depends on | backport | 0054486 | PR24Q1.1 | closed | Triage Platform Base | Avoid compiler warning about implicit annotation processing by disabling it using -proc:none | related to | feature request | 0054487 | | closed | Triage Platform Base | Avoid compiler warning about implicit annotation processing by disabling it using -proc:none (selenium code) | blocks | feature request | 0054449 | | new | Triage Platform Base | Support JDK21 (LTS) |
|
Attached Files | |
|
Issue History |
Date Modified | Username | Field | Change |
2024-01-24 13:37 | shuehner | New Issue | |
2024-01-24 13:37 | shuehner | Assigned To | => Triage Platform Base |
2024-01-24 13:37 | shuehner | Modules | => Core |
2024-01-24 13:37 | shuehner | Triggers an Emergency Pack | => No |
2024-01-24 13:37 | shuehner | Relationship added | blocks 0054449 |
2024-01-24 14:12 | hgbot | Note Added: 0159714 | |
2024-01-29 10:52 | shuehner | Status | new => scheduled |
2024-01-29 10:52 | shuehner | Note Added: 0159848 | |
2024-01-29 11:54 | shuehner | Issue cloned | 0054487 |
2024-01-29 11:54 | shuehner | Relationship added | related to 0054487 |
2024-02-09 20:04 | hgbot | Resolution | open => fixed |
2024-02-09 20:04 | hgbot | Status | scheduled => closed |
2024-02-09 20:04 | hgbot | Note Added: 0160589 | |
2024-02-09 20:04 | hgbot | Fixed in Version | => PR24Q2 |
2024-02-09 20:04 | hgbot | Note Added: 0160590 | |
Notes |
|
(0159714)
|
hgbot
|
2024-01-24 14:12
|
|
|
|
|
Add 24Q1 backport (same as initially targeted in 53971) |
|
|
(0160589)
|
hgbot
|
2024-02-09 20:04
|
|
|
|
(0160590)
|
hgbot
|
2024-02-09 20:04
|
|
Directly closing issue as related merge request is already approved.
Repository: https://gitlab.com/openbravo/product/openbravo [^]
Changeset: d44524d61960aa4765a54c4c0d60d9bc99f68888
Author: adrian.blasco <adrian.blasco@openbravo.com>
Date: 09-02-2024 20:02:40
URL: https://gitlab.com/openbravo/product/openbravo/-/commit/d44524d61960aa4765a54c4c0d60d9bc99f68888 [^]
Fixed ISSUE-54452: Disable annotation processing with -proc:none to avoid warnings
Until Java<21 the java compiler implicitely looked for and ran any
annotation processor found on the classpath.
Since Java21 the following warning is shown to inform users about upcoming change of
default for this policy.
[javac] Note: Annotation processing is enabled because one or more processors were found
[javac] on the class path. A future release of javac may disable annotation processing
[javac] unless at least one processor is specified by name (-processor), or a search
[javac] path is specified (--processor-path, --processor-module-path), or annotation
[javac] processing is enabled explicitly (-proc:only, -proc:full).
[javac] Use -Xlint:-options to suppress this message.
[javac] Use -proc:none to disable annotation processing.
- Add a new ant property javac.proc to specify value to be used via
<compilerarg line> for all our various javac invocations
- For the value use -proc:none to explicitely disable annotation processing
during compilation
<compilearg line> was chosne as <compiler arg> value run into some
cornercase issues in case value was empty.
- Reasoning:
- Upstream recommends to explcitely specify and control annotation
processors instead of them being 'found' implicitely
https://github.com/openjdk/jdk/pull/14432#issuecomment-1714598354 [^]
- Checking all jar libraries in mods/pmods (if they ship a
META-INF/avax.annotation.processing.Processor) file found 1 single library
shipping an annotation processor: log4j for its plugin system
- However we do not use any shipped extra plugin
- We have a few custom plugins ourself in src-test having @Plugin
- Annotation processing was running before for those as shown on
compile output
[javac] Note: Processing Log4j annotations
[javac] Note: Annotations processed
- However not running it seems to have no impact on the functionality
- Tested via existing DalTest which assert's on output of content of
testLogAppender configured via those plugins
---
M build.xml
M src-core/build.xml
M src-test/build.xml
M src-trl/build.xml
M src-util/buildvalidation/build.xml
M src-util/modulescript/build.xml
M src-wad/build.xml
M src/build.xml
---
|
|