Console messsages

I would like to suppress the following messages appearing in the console.

How to do that?

--

Jun 11, 2007 1:38:05 PM ClientCommunicatorAdmin restart

WARNING: Failed to restart: java.net.ConnectException: Connection refused: connect

Jun 11, 2007 1:38:06 PM ClientIntermediary close

INFO: java.io.IOException: The connection is not currently established.

java.io.IOException: The connection is not currently established.

at com.sun.jmx.remote.generic.ClientSynchroMessageConnectionImpl.checkState(ClientSynchroMes

sageConnectionImpl.java:577)

at com.sun.jmx.remote.generic.ClientSynchroMessageConnectionImpl.sendOneWay(ClientSynchroMes

sageConnectionImpl.java:162)

at javax.management.remote.generic.GenericConnector.close(GenericConnector.java:260)

at javax.management.remote.generic.GenericConnector.close(GenericConnector.java:231)

at javax.management.remote.generic.ClientIntermediary$GenericClientCommunicatorAdmin.doStop(

ClientIntermediary.java:839)

at com.sun.jmx.remote.opt.internal.ClientCommunicatorAdmin.restart(ClientCommunicatorAdmin.j

ava:133)

at com.sun.jmx.remote.opt.internal.ClientCommunicatorAdmin.gotIOException(ClientCommunicator

Admin.java:34)

at javax.management.remote.generic.GenericConnector$RequestHandler.connectionException(Gener

icConnector.java:667)

at com.sun.jmx.remote.generic.ClientSynchroMessageConnectionImpl$MessageReader.run(ClientSyn

chroMessageConnectionImpl.java:408)

at com.sun.jmx.remote.opt.util.ThreadService$ThreadServiceJob.run(ThreadService.java:208)

at com.sun.jmx.remote.opt.util.JobExecutor.run(JobExecutor.java:59)

[1723 byte] By [Valasua] at [2007-11-27 7:05:02]
# 1

Hi,

You can use the java.util.logging API to do that.

The simplest is to set the log level for javax.management.remote.misc to SEVERE

and for javax.management.remote.generic to WARNING in your logging.property

file.

// disable the WARNING trace

javax.management.remote.misc.level=SEVERE

// disable the INFO stack trace

javax.management.remote.generic.level=WARNING

http://java.sun.com/j2se/1.5.0/docs/guide/logging/overview.html

http://java.sun.com/developer/TechTips/txtarchive/2002/Oct02_JohnZ.txt

regards,

-- daniel

JMX, SNMP, Java, etc...

http://blogs.sun.com/jmxetc

dfuchsa at 2007-7-12 18:56:20 > top of Java-index,Core,Monitoring & Management...