Bug 835699 - [as7] Warnings When Loading Resource Configuration
Summary: [as7] Warnings When Loading Resource Configuration
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: RHQ Project
Classification: Other
Component: Plugins
Version: 4.4
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
: JON 3.1.1
Assignee: Armine Hovsepyan
QA Contact: Mike Foley
URL:
Whiteboard:
Depends On: 831369
Blocks: as7-plugin
TreeView+ depends on / blocked
 
Reported: 2012-06-26 20:58 UTC by Stefan Negrea
Modified: 2015-09-03 00:01 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of: 831369
Environment:
Last Closed: 2013-09-03 15:08:09 UTC
Embargoed:


Attachments (Terms of Use)
agent.log (71.87 KB, text/x-log)
2012-08-06 14:26 UTC, Armine Hovsepyan
no flags Details

Description Stefan Negrea 2012-06-26 20:58:50 UTC
+++ This bug was initially created as a clone of Bug #831369 +++

Description of problem:

Warnings are logged by the agent when loading resource configuration for all the AS7 plugin resources. Here is an example:

12:14:09,940 WARN  [ASConnection] Received 500 (Internal Server Error) response to Operation{operation='read-attribute', address=Address{path: subsystem=transactions,log-store=log-store}, additionalProperties={name=name}} - response body was [{"outcome" : "failed", "failure-description" : "JBAS014792: Unknown attribute name", "rolled-back" : true, "response-headers" : {"process-state" : "reload-required"}}].

The error is harmless. The error is due executing an extra operation to discover the server state (normal, reload required, restart required). The operation executed is :read-attribute with "name" as the name of the attribute. This operation will fail for any sub-resource that does not have "name" in the definition. While the operation fails, it still returns the correct server state. There are no side effects other than log entries.


How reproducible:
Every time

Steps to Reproduce:
1. Discover and import an AS7 server.
2. Select a resource that has configuration available and to the configuration tab.
3. Look in the agent logs and notice the above error.
  
Actual results:
Warning added to the agent log

Expected results:
No warnings in the agent log


Additional info:
The solution, instead of using :read-attribute operation to detect server state, use :whoami. This operation is present on all resources, does not require any attributes, and does return the server state.

--- Additional comment from snegrea on 2012-06-12 17:24:48 EDT ---

Updated the plugin to use :whoami to retrieve server state.

Comment 1 Stefan Negrea 2012-07-20 21:22:09 UTC
release/jon3.1.x branch commit:

http://git.fedorahosted.org/git/?p=rhq/rhq.git;a=commit;h=a851500532e8e3b2559ebaffe515e7b68ab57e88

Comment 2 John Sanda 2012-08-02 18:52:04 UTC
JON 3.1.1 ER1 build is available. Moving to ON_QA.

https://brewweb.devel.redhat.com/buildinfo?buildID=226942

Comment 3 Armine Hovsepyan 2012-08-06 14:26:07 UTC
Created attachment 602528 [details]
agent.log

reopened.

the errors are still visible.

Comment 4 Stefan Negrea 2012-08-07 21:33:18 UTC
The log does not have any errors related to the name property. The log still contains typical discovery warnings because the server was started without some subsystems.


Please look again in the logs for errors of the following type:

12:14:09,940 WARN  [ASConnection] Received 500 (Internal Server Error) response to Operation{operation='read-attribute', address=Address{path: subsystem=transactions,log-store=log-store}, additionalProperties={name=name}} - response body was [{"outcome" : "failed", "failure-description" : "JBAS014792: Unknown attribute name", "rolled-back" : true, "response-headers" : {"process-state" : "reload-required"}}].


Note the additionalProperties={name=name} part and the error related to it being an unknown attribute.

Comment 5 Armine Hovsepyan 2012-08-08 08:59:48 UTC
verified.

No Internal Server error for read-attribute with name=name is visible in the logs.

Comment 6 Heiko W. Rupp 2013-09-03 15:08:09 UTC
Bulk closing of old issues in VERIFIED state.


Note You need to log in before you can comment on or make changes to this bug.