Anonymous | Login
News | My View | View Issues | Roadmap | Summary

View Issue DetailsJump to Notes ] Issue History ] Print ]
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Tools] Othersmajoralways2018-10-29 16:422018-11-08 09:56
ReporterjarmendarizView Statuspublic 
Assigned Tojarmendariz 
StatusclosedFix in branchFixed in SCM revision
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Review Assigned Toalostale

0039557: Eclipse warnings task fails when processing log4j annotations

DescriptionThe project compiles without errors in Eclipse IDE. However, using the ecj batch compiler in the eclipse-warnings task it fails in the annotation processing step with the following message:

Processing annotations
java.lang.IllegalArgumentException: Unknown location : CLASS_OUTPUT
    at org.eclipse.jdt.internal.compiler.apt.util.EclipseFileManager.getFileForOutput(
    at org.eclipse.jdt.internal.compiler.apt.dispatch.BatchFilerImpl.createResource(
    at org.apache.logging.log4j.core.config.plugins.processor.PluginProcessor.writeCacheFile(
    at org.apache.logging.log4j.core.config.plugins.processor.PluginProcessor.process(
    at org.eclipse.jdt.internal.compiler.apt.dispatch.RoundDispatcher.handleProcessor(
    at org.eclipse.jdt.internal.compiler.apt.dispatch.RoundDispatcher.round(
    at org.eclipse.jdt.internal.compiler.apt.dispatch.BaseAnnotationProcessorManager.processAnnotations(
    at org.eclipse.jdt.internal.compiler.Compiler.processAnnotations(
    at org.eclipse.jdt.internal.compiler.Compiler.compile(
    at org.eclipse.jdt.internal.compiler.Compiler.compile(
    at org.eclipse.jdt.internal.compiler.batch.Main.performCompilation(
    at org.eclipse.jdt.internal.compiler.batch.Main.compile(
    at org.eclipse.jdt.internal.compiler.batch.Main.main(
Processing annotations
No elements to process
1. ERROR: Unknown location : CLASS_OUTPUT
1 problem (1 error)

This issue has already been reported in:
- Stack Overflow: [^]
- Log4j Jira: [^]
- Eclipse issue tracker: [^]
Steps To ReproduceThe following repository contains a minimal scenario to reproduce this issue: [^]

Just clone this repository and execute
Proposed SolutionUntil either Eclipse/Apache comes with a patch to solve this issue, log4j's annotation processor can be skipped in batch build by removing META-INF/services/javax.annotation.processing.Processor in log4j-core-x.y.z.jar.

This should be done only in eclipse-warnings task.
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]
related to feature request 0039504 closedjarmendariz Openbravo ERP Upgrade Log4j to version 2 

-  Notes
jarmendariz (developer)
2018-10-30 14:28

Repository: ci/eclipse-warnings
Changeset: ada4fd8fd3c2
Author: Javier Armendáriz <javier.armendariz <at>>
Date: Mon, 29 Oct 2018 17:24:08 +0100
URL: [^]

Fixed issue 39557: Ecj fails when processing log4j annotations

This replaces the log4j-core library in the classpath with a customized jar with
no annotation processing as a workaround until this bug is solved. Also wrapped all
js code in CDATA tags to avoid problems with the && operator.

M build-eclipse.xml
A log4j-core-2.11.1.jar

- Issue History
Date Modified Username Field Change
2018-10-29 16:42 jarmendariz New Issue
2018-10-29 16:44 jarmendariz Relationship added related to 0039504
2018-10-29 16:45 jarmendariz Assigned To => jarmendariz
2018-10-29 16:45 jarmendariz Status new => scheduled
2018-10-30 14:28 jarmendariz Note Added: 0107658
2018-10-30 14:28 jarmendariz Status scheduled => resolved
2018-10-30 14:28 jarmendariz Resolution open => fixed
2018-10-30 14:29 jarmendariz Review Assigned To => alostale
2018-11-08 09:56 alostale Status resolved => closed

Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker