Bug 1287094 - A-MQ hawt.io console deleting queue does not remove it from the tree view
A-MQ hawt.io console deleting queue does not remove it from the tree view
Product: OpenShift Container Platform
Classification: Red Hat
Component: Management Console (Show other bugs)
Unspecified Unspecified
unspecified Severity low
: ---
: ---
Assigned To: stlewis@redhat.com
Marek Schmidt
Depends On:
  Show dependency treegraph
Reported: 2015-12-01 08:54 EST by Marek Schmidt
Modified: 2016-09-07 17:03 EDT (History)
5 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2016-09-07 17:03:18 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Marek Schmidt 2015-12-01 08:54:49 EST
Description of problem:

After deleting a Queue in the ActiveMQ Hawt.io console, the queue is still visible in the tree view on the left. 

Opening the console again make the queue disappear, so this is really just the  view not being refreshed.

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


How reproducible:

Steps to Reproduce:
1. Update xPaaS A-MQ image stream to use rcm-img-docker01.build.eng.bos.redhat.com:5001/jboss-amq-6/amq62-openshift:1.2-6  (as the previous version lack the jolokia integration for the hawt.io console to work)

2. Deploy A-MQ using the updated xPaaS template 

3. locate the A-MQ pod in the OpenShift console and click 'Connect' 

4. Crate a 'fooBar' queue.

5. Delete the 'fooBar' queue

Actual results:

Queue is deleted, but is still visible in the Queue folder in the tree view on the left

Expected results:

Removed queue should disappear also from the treee view.

Additional info:

Reproducible with both Firefox and Chrome
Comment 1 stlewis@redhat.com 2015-12-01 12:56:44 EST
So far it seems to work here, but let's check a couple things, can you open up the javascript console and type in the following:


It should be '5000', and actually is supposed to be configurable but I see that particular preference page isn't available, so will need to fix that for starters.

The actual entry from the tree isn't removed until the next poll occurs, so it's asynchronous from deleting the queue, I'd expect though for the AMQ tree to refresh itself at most 5 seconds after the delete function completes.  Can you also check the 'Network' tab  in the javascript console, you should see a steady stream of requests to the jolokia endpoint with HTTP 200 responses assuming all is well.
Comment 2 stlewis@redhat.com 2015-12-02 11:03:05 EST
Not a fix for the specific issue, but since I mentioned I'd fix it, this commit adds back in the update rate setting into the preferences, will show up in the 'Jolokia' page:


Still waiting to hear back, as I can't seem to reproduce this locally at least.
Comment 3 Marek Schmidt 2015-12-02 14:28:40 EST
localStorage['updateRate'] is 5000 

I see stream of POST requests to https://cloudenablement-qe4.lab.eng.brq.redhat.com:8443/api/v1/namespaces/maschmid/pods/https:amq-1-9jfsr:8778/proxy/jolokia/?maxDepth=7&maxCollectionSize=500&ignoreErrors=true&canonicalNaming=false  once per 5 seconds.

The removed queue will disappear if I switch to "JMX" or "Threads" view and back to "ActiveMQ" again, so at least that seem to refresh the tree.
Comment 4 stlewis@redhat.com 2016-01-12 09:34:32 EST
Fix mentioned above is in this PR -> https://github.com/openshift/origin/pull/6539
Comment 5 yapei 2016-01-12 21:02:26 EST
fix is not included in current latest puddle, will verify once merged in new OSE puddle
Comment 6 Marek Schmidt 2016-01-19 07:48:25 EST
Still reproducible with the current puddle (openshift-jvm Version: 1.0.39 Commit ID: e79966878b9aba11b77fcb69db2cbbba12c662c9 ), oc v3.1.1.5, kubernetes v1.1.0-origin-1107-g4c8e6f4 )

Used the latest A-MQ image from RCM ( rcm-img-docker01.build.eng.bos.redhat.com:5001/jboss-amq-6/amq62-openshift:1.2-12 )
Comment 7 stlewis@redhat.com 2016-01-29 13:09:42 EST
Realized that this is by design in a way.  We avoid fetching the JMX tree regularly as it can contain a lot of data.  Normally we get around this by keeping an eye on a special TreeWatcher mbean, however if this mbean isn't available in the tree we have to degrade to refreshing the tree less.

Will probably look at adding a tree refresh when the delete operation completes.
Comment 8 stlewis@redhat.com 2016-02-01 10:36:52 EST
Here's the fix -> https://github.com/hawtio/hawtio-integration/commit/d5bd0fc642e12dcf6be14bacdaef8d786cd1b278

Will be in this openshift-jvm version -> https://github.com/hawtio/openshift-jvm/commit/d46658f96d3134f99b0b6073433d4366defaee0f

Will update once I've submitted a PR...
Comment 9 stlewis@redhat.com 2016-02-01 11:04:51 EST
PR => https://github.com/openshift/origin/pull/6938
Comment 10 Marek Schmidt 2016-02-17 07:24:14 EST
Verified on current 3.2 Puddle  (the tree is still not updated in another browser window when queues are added or deleted, but as you said, that is by design to not refresh the tree)

(openshift-jvm Version: 1.0.42 Commit ID: d46658f96d3134f99b0b6073433d4366defaee0f )

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