8

I'm using Eclipse Kepler with Tomcat 7, I'm just testing a simple JSP page (test.jsp). It runs well in browser however all text in console is displayed in color red.

I have checked in Window/Preferences/(Run/Debug) properties and all seams to be fine.

The text from the console is the following:

Jan 07, 2015 3:31:07 PM org.apache.catalina.core.AprLifecycleListener init
INFO: The APR based Apache Tomcat Native library which allows optimal performance 
in production environments was not found on the java.library.path: 
C:\Java\jdk1.8.0_05\jre\bin;C:\Windows\Sun\Java\bin;C:\Windows\system32;...etc
Jan 07, 2015 3:31:08 PM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["http-bio-8080"]
Jan 07, 2015 3:31:08 PM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["ajp-bio-8009"]
Jan 07, 2015 3:31:08 PM org.apache.catalina.startup.Catalina load 
INFO: Initialization processed in 1676 ms
Jan 07, 2015 3:31:08 PM org.apache.catalina.core.StandardService startInternal
INFO: Starting service Catalina
Jan 07, 2015 3:31:08 PM org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet Engine: Apache Tomcat/7.0.56
Jan 07, 2015 3:31:11 PM org.apache.catalina.util.SessionIdGenerator createSecureRandom
INFO: Creation of SecureRandom instance for session ID generation using [SHA1PRNG] took 
[1,076] milliseconds.
Jan 07, 2015 3:31:12 PM org.apache.catalina.startup.HostConfig deployDescriptor
INFO: Deploying configuration descriptor 
C:\MauricioFiles\ECLIPSE\Eclipse_JEE7_I\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\conf
\Catalina\localhost\Servlets_JSP_chapter21_musicII.xml
Jan 07, 2015 3:31:12 PM org.apache.catalina.startup.SetContextPropertiesRule begin
WARNING: [SetContextPropertiesRule]{Context} Setting property 'source' to      
'org.eclipse.jst.jee.server:
Servlets_JSP_chapter21_musicII' did not find a matching property.
Jan 07, 2015 3:31:12 PM org.apache.catalina.startup.HostConfig deployDescriptor
INFO: Deployment of configuration descriptor   
C:\MauricioFiles\ECLIPSE\Eclipse_JEE7_I\.metadata\.plugins
\org.eclipse.wst.server.core\tmp0\conf\Catalina\localhost\Servlets_JSP_chapter21_musicII.xml has    
finished in 862 ms
Jan 07, 2015 3:31:12 PM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["http-bio-8080"]
Jan 07, 2015 3:31:13 PM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["ajp-bio-8009"]
Jan 07, 2015 3:31:13 PM org.apache.catalina.startup.Catalina start
INFO: Server startup in 4236 ms

Is something wrong with the proyect or is there a way to display text in black (just error in red)? Thank you a lot!!

MauricioTL
  • 343
  • 1
  • 5
  • 17
  • possible duplicate of [Tomcat STDOUT as Error in Eclipse](http://stackoverflow.com/questions/3365280/tomcat-stdout-as-error-in-eclipse) – Nathan Hughes Jun 16 '15 at 15:48

1 Answers1

4

The text that is in red is being written to the System.err stream, the text in black is written to System.out. Nothing is inherently wrong, that's just how the system is differentiating the output streams. You can configure the display to your liking by right clicking in the console and selecting "Preferences"

eclipse console preferense

Elliott Frisch
  • 198,278
  • 20
  • 158
  • 249
  • Thanks. My console preferences look the same as in image, but color is always red, could there be any other thing I could changed to avoid all text in red? Thank you. – MauricioTL Jan 07 '15 at 22:14
  • 1
    Reconfigure your logger, or change the color. Click on the red rectangle above and set it to black. Or uncheck show when program writes to standard error. Or explain what you mean please... – Elliott Frisch Jan 07 '15 at 22:16
  • ok. that is interesting, thank you for this answer, it explains the tomcat-behavior well. but i think this is more like a workaround. i prefer it when tomcat simply do not write anything to stderr unless it is really an error. information should go to stdout. i hope the developer of tomcat will also have this opinion someday... – anion Oct 06 '19 at 20:09