Eclipse console not showing any error/log output

15,353

Issue will fix with adding following VM argument in your server

Please Go Eclipse->Server Tab -> Click on Open Launch Configuration ->VM arguments

And add this argument in VM argument section

-Dorg.jboss.as.logging.per-deployment=false

Here in this link more and detail about the issue

After reading what has been said in this thread, I'm trying to summarize the use of the per-deployment flag:

1.0 When per-deployment is true (default):

1.1 AS7.1.2 is scanning for logging configuration files in your deployment (WAR), If a configuration file is found then that deployment will get its own log context and be configured via the configuration file.

1.2 Once the properties file is found, it will be read and the application logging will go to wherever it has been specified to log (with the corresponding handler).

1.3 Logging jars don't need to be included with the application.

2.0 Setting the flag to false disables this feature, and the deployment scanner will not look for these files. Therefore:

2.1 You have to use the jboss-deployment-structure.xml to exclude the AS server's logging dependencies you are using and include them into your deployment.

2.2 Logging functionality is left up to the application. The application should have all the configuration files and required libraries (That's why the server's libraries have to be excluded)

2.3 If the application had, for example, a log4j.xml but no log4j dependency. The application will stop logging.

Personally, I'm using -Dorg.jboss.as.logging.per-deployment=false when I get missing dependencies errors at during deployment so that it displays in the console the stack trace for the missing class. Otherwise the only error we get in AS7's console (and server.log) is: Services with missing/unavailable dependencies Which does not make it easy to track down the missing dependency.

Share:
15,353
Subodh Joshi
Author by

Subodh Joshi

A Developer from India . I convert caffeine into code. Trying to Select * from life; if (FAIL) { keepTrying(); } else{ keepTrying(); }

Updated on June 29, 2022

Comments

  • Subodh Joshi
    Subodh Joshi almost 2 years

    I am using Eclipse Kepler and i am running Java Web application in Jboss EAP 6.1 . Today morning i noticed after deploying and running my web application no console output is coming.

    But console output showing when i am starting Jboss and its show everything which all application deployed etc. But after that nothing is printing in console .

    Can someone please guild me what can be cause i tried plenty of thing mentioned in different -2 question posted in Stackoverflow.

    UPDATE :-

    I tried below code

    public class test {
    
      public static void main(String arg[]){
        System.out.println("hariom");
      }
    }
    

    and its result printing in console but when i am deploying and running web application then only its not showing anything.