Bug 727963

Summary: WARNings spewing out on RHQ Agent console
Product: [Other] RHQ Project Reporter: Mike Foley <mfoley>
Component: AgentAssignee: Stefan Negrea <snegrea>
Status: CLOSED CURRENTRELEASE QA Contact: Mike Foley <mfoley>
Severity: unspecified Docs Contact:
Priority: high    
Version: 4.1CC: hrupp, mazz
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 625146    

Description Mike Foley 2011-08-03 19:21:34 UTC
Description of problem: WARNings spewing out on RHQ Agent console after doing "plugins update" after importing mod-cluster plugin


Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1.  import mod-cluster plugin
2.  do "plugins update" on the agent
3.
  
Actual results:
WARN messages spew to console.

Expected results:
WARN messages are written to the log file.


Additional info:
> plugins update
The plugin container has been stopped.
Updating plugins to their latest versions.
The plugin [mod_cluster] has been updated at [modcluster-plugin-4.1.0-SNAPSHOT.jar].
Completed updating the plugins to their latest versions.
WARN: The method class org.apache.commons.logging.impl.SLF4JLogFactory#release() was invoked.
WARN: Please see http://www.slf4j.org/codes.html#release for an explanation.
The plugin container has been started.
> WARN: The method class org.apache.commons.logging.impl.SLF4JLogFactory#release() was invoked.
WARN: Please see http://www.slf4j.org/codes.html#release for an explanation.
WARN: The method class org.apache.commons.logging.impl.SLF4JLogFactory#release() was invoked.
WARN: Please see http://www.slf4j.org/codes.html#release for an explanation.
WARN: The method class org.apache.commons.logging.impl.SLF4JLogFactory#release() was invoked.
WARN: Please see http://www.slf4j.org/codes.html#release for an explanation.
WARN: The method class org.apache.commons.logging.impl.SLF4JLogFactory#release() was invoked.
WARN: Please see http://www.slf4j.org/codes.html#release for an explanation.

Comment 1 John Mazzitelli 2011-08-05 13:29:45 UTC
I think I know what this is.

Is this talking to a JBossAS 5, 6 or 7?

The JBossAS client code is using a logger that is spewing this out. The jboss-as plugin will need to define its own log configuration and set it properly before using the JBoss client.

We need to make sure we do NOT spit out anything to the console. Its hard to ensure plugins follow that rule (the agent and plugin container core code ensures this), but for our own plugins, we need to make sure this is true.

This means:
1) NO System.out.print
2) NO System.err.print
3) NO Execution.printStackTrace()
4) NO logging to the console

Comment 2 Stefan Negrea 2011-08-28 16:29:20 UTC
Updated the code to declare the logger locally before using it (per the recommendations above). The logger declared at parent level was issuing usage warnings on the agent container.

Comment 4 Mike Foley 2011-08-30 20:27:29 UTC
this is verified.  i did see another logging message outputing on the agent console ... which i logged in this BZ:  https://bugzilla.redhat.com/show_bug.cgi?id=734486

Comment 5 Mike Foley 2012-02-07 19:30:06 UTC
changing status of VERIFIED BZs for JON 2.4.2 and JON 3.0 to CLOSED/CURRENTRELEASE

Comment 6 Mike Foley 2012-02-07 19:30:28 UTC
marking VERIFIED BZs to CLOSED/CURRENTRELEASE