[
https://issues.jboss.org/browse/WFCORE-2995?page=com.atlassian.jira.plugi...
]
Geoffrey De Smet edited comment on WFCORE-2995 at 6/21/17 6:50 PM:
-------------------------------------------------------------------
Hi James, thanks for looking into this.
I did originally exclude the logging subsystem in jboss-deployment-structure.xml, but then
I got logging like this in my console:
{code}
10:42:20,436 INFO [stdout] (EE-ManagedExecutorService-default-Thread-1) 2017-06-21
10:42:20,436 [EE-ManagedExecutorService-default-Thread-1] DEBUG LS step (124984), time
spent (29999), score (0hard/200soft), best score (0hard/240soft), accepted/selected
move count (1/12), picked move (Lights 2017-02-01T06:00-14:00 {Gus Rye -> Dan King}).
10:42:20,436 INFO [stdout] (EE-ManagedExecutorService-default-Thread-1) 2017-06-21
10:42:20,436 [EE-ManagedExecutorService-default-Thread-1] DEBUG LS step (124985), time
spent (29999), score (0hard/200soft), best score (0hard/240soft), accepted/selected
move count (1/27), picked move (Engine 2017-02-02T14:00-22:00 {Hugo Watt} <->
Sunroof 2017-02-02T14:00-22:00 {Dan Li}).
10:42:20,437 INFO [stdout] (EE-ManagedExecutorService-default-Thread-1) 2017-06-21
10:42:20,437 [EE-ManagedExecutorService-default-Thread-1] DEBUG LS step (124986), time
spent (30000), score (-1hard/200soft), best score (0hard/240soft), accepted/selected
move count (0/38), picked move (Sunroof 2017-02-01T06:00-14:00 {Flo Poe} <-> Lights
2017-02-01T14:00-22:00 {Ivy Watt}).
10:42:20,437 INFO [stdout] (EE-ManagedExecutorService-default-Thread-1) 2017-06-21
10:42:20,437 [EE-ManagedExecutorService-default-Thread-1] INFO Local Search phase (1)
ended: time spent (30000), best score (0hard/240soft), score calculation speed
(66502/sec), step total (124987).
10:42:20,437 INFO [stdout] (EE-ManagedExecutorService-default-Thread-1) 2017-06-21
10:42:20,437 [EE-ManagedExecutorService-default-Thread-1] INFO Solving ended: time spent
(30000), best score (0hard/240soft), score calculation speed (65469/sec), phase total (2),
environment mode (REPRODUCIBLE).
{code}
Every line says the time, level and thread twice.
The {{10:42:20,436 INFO [stdout] (EE-ManagedExecutorService-default-Thread-1)}} prefix is
from JBoss and shouldn't be there, so it only has the logback pattern {{2017-06-21
10:42:20,436 [EE-ManagedExecutorService-default-Thread-1] DEBUG ...}}
was (Author: ge0ffrey):
Hi James, thanks for looking into this.
I did originally exclude the logging subsystem in jboss-deployment-structure.xml, but then
I got logging like this in my console:
{code}
10:42:20,436 INFO [stdout] (EE-ManagedExecutorService-default-Thread-1) 2017-06-21
10:42:20,436 [EE-ManagedExecutorService-default-Thread-1] DEBUG LS step (124984), time
spent (29999), score (0hard/200soft), best score (0hard/240soft), accepted/selected
move count (1/12), picked move (Lights 2017-02-01T06:00-14:00 {Gus Rye -> Dan King}).
10:42:20,436 INFO [stdout] (EE-ManagedExecutorService-default-Thread-1) 2017-06-21
10:42:20,436 [EE-ManagedExecutorService-default-Thread-1] DEBUG LS step (124985), time
spent (29999), score (0hard/200soft), best score (0hard/240soft), accepted/selected
move count (1/27), picked move (Engine 2017-02-02T14:00-22:00 {Hugo Watt} <->
Sunroof 2017-02-02T14:00-22:00 {Dan Li}).
10:42:20,437 INFO [stdout] (EE-ManagedExecutorService-default-Thread-1) 2017-06-21
10:42:20,437 [EE-ManagedExecutorService-default-Thread-1] DEBUG LS step (124986), time
spent (30000), score (-1hard/200soft), best score (0hard/240soft), accepted/selected
move count (0/38), picked move (Sunroof 2017-02-01T06:00-14:00 {Flo Poe} <-> Lights
2017-02-01T14:00-22:00 {Ivy Watt}).
10:42:20,437 INFO [stdout] (EE-ManagedExecutorService-default-Thread-1) 2017-06-21
10:42:20,437 [EE-ManagedExecutorService-default-Thread-1] INFO Local Search phase (1)
ended: time spent (30000), best score (0hard/240soft), score calculation speed
(66502/sec), step total (124987).
10:42:20,437 INFO [stdout] (EE-ManagedExecutorService-default-Thread-1) 2017-06-21
10:42:20,437 [EE-ManagedExecutorService-default-Thread-1] INFO Solving ended: time spent
(30000), best score (0hard/240soft), score calculation speed (65469/sec), phase total (2),
environment mode (REPRODUCIBLE).
{code}
Every line says the time, level and thread twice.
The {code}10:42:20,436 INFO [stdout] (EE-ManagedExecutorService-default-Thread-1){code}
prefix is from JBoss and shouldn't be there, so it only has the logback pattern
{code}2017-06-21 10:42:20,436 [EE-ManagedExecutorService-default-Thread-1] DEBUG
...{code}
WildFly: support logback.xml in Per-deployment Logging (instead of
silently ignoring logback.xml)
-------------------------------------------------------------------------------------------------
Key: WFCORE-2995
URL:
https://issues.jboss.org/browse/WFCORE-2995
Project: WildFly Core
Issue Type: Feature Request
Components: Logging
Reporter: Geoffrey De Smet
Assignee: James Perkins
Wildfly currently supports the following _Per deployment logging_ configurations [1]:
logging.properties
jboss-logging.properties
log4j.properties
log4j.xml
jboss-log4j.xml
All of these are stale because they are based on Log4j 1.x format which died about 8
years ago (along with using properties files for logging configuration).
Modern popular options include Logback (with SLF4J), JBoss Logging and Log4j 2.x.
*I regularly see WildFly users (included RH employees) that struggle to configure the
logging configuration of their WildFly apps.* Spring Boot does not have this problem. _To
fix this, WildFly should support logback.xml for Per deployment logging too._
When I add a logback.xml in my war's WEB-INF/classes directory and explicitly add the
logback-classic.jar in WEB-INF/lib directory - which works to configure Logback in any
other JVM - then WildFly ignores it (~ it says GFY). My logs doesn't show up and
developing on WildfFly is a pain due to blindness.
Fake solution: Configuring the log files per WildFly installation is not practical for
developers (it is for sys admins): the log configuration should be in my war's sources
on github, so other developers automatically have it without needing to jump to wildfly
installation hoops (which is sometimes not possible, think OpenShift).
Although it's ok that WildFly favors JBoss Logging, it should not dictate it and
support other logging systems such as Logback too for the war files at least (= per
deployment).
[1]
https://docs.jboss.org/author/display/WFLY10/Logging+Configuration
--
This message was sent by Atlassian JIRA
(v7.2.3#72005)