This is a short article explaining how to migrate your Java applications running with Log4j 1.x to Log4j 2.x with special focus on WildFly / JBoss EAP.
How to solve java.lang.NoSuchFieldError: EMPTY_BYTE_ARRAY
When deploying applications on WildFly, encountering a log4j2 core libs and log4j2 API mismatch issue is not uncommon. This issue, presented as java.lang.NoSuchFieldError: EMPTY_BYTE_ARRAY, arises due to discrepancies between the Log4j2 core libraries used within the application and the Log4j2 API provided by WildFly’s modules. Cause: Firstly, the mismatch occurs when the application uses a … Read more