Bug 970177 - Cannot browse the GUI while the plugin scan is running
Cannot browse the GUI while the plugin scan is running
Status: CLOSED CURRENTRELEASE
Product: RHQ Project
Classification: Other
Component: Core Server (Show other bugs)
4.7
Unspecified Unspecified
urgent Severity medium (vote)
: ---
: RHQ 4.8
Assigned To: Thomas Segismont
Mike Foley
:
Depends On:
Blocks: 970714
  Show dependency treegraph
 
Reported: 2013-06-03 11:35 EDT by Thomas Segismont
Modified: 2013-09-11 05:53 EDT (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 970714 (view as bug list)
Environment:
Last Closed: 2013-09-11 05:53:50 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
Exception stack trace (7.72 KB, text/plain)
2013-06-03 11:35 EDT, Thomas Segismont
no flags Details

  None (edit)
Description Thomas Segismont 2013-06-03 11:35:29 EDT
Created attachment 756367 [details]
Exception stack trace

Description of problem:
Cannot browse the GUI if the plugin scan task does not execute quickly.

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

How reproducible:
Always

Steps to Reproduce:
1.Upload a new (version of a) plugin with various resource types (ie as7 plugin)
2.Wait for the plugin scan task to start (look at the server logs)
3.While the server is updating resource types, try to browse the GUI

Actual results:
Cannot browse the GUI and the server logs shows the attached stack trace

Expected results:
Can browse the GUI

Additional info:
The plugin scan is currently triggered with an EJB timer in a @Singleton bean (org.rhq.enterprise.server.core.StartupBean). Those beans by default have container managed concurrency. Without any annotations, the container serializes calls to the bean. So the AuthenticationFilter timeouts on its try to call org.rhq.enterprise.server.core.StartupLocal#isInitialized
Comment 1 Thomas Segismont 2013-06-03 11:58:24 EDT
Comments from IRC

<mazz> BTW, there are other @Singleton SLSBs we should examine for this same kind of thing
<mazz> I see two that we should look at
<mazz> org.rhq.enterprise.server.cassandra.SessionManagerBean
<mazz> (that's something jsanda put together for the storage stuff)
<mazz> and org.rhq.enterprise.server.auth.prefs.SubjectPreferencesCacheBean
Comment 2 John Mazzitelli 2013-06-03 12:06:44 EDT
(In reply to Thomas Segismont from comment #1)
> <mazz> BTW, there are other @Singleton SLSBs we should examine for this same
> kind of thing
> <mazz> and org.rhq.enterprise.server.auth.prefs.SubjectPreferencesCacheBean

That SubjectPreferencesCacheBean is OK - I remember doing this. Its explicitly marked as CONTAINER and we use the EJB LOCK annotations to ensure we have read/write locking around the appropriate places.

We should ask John S. just to confirm that SessionManagerBean is OK.
Comment 3 Thomas Segismont 2013-06-06 17:13:06 EDT
Fixed in master

commit d10f9a5c01e28584e1d07c7a556f446de7e22cbe
Author: Thomas Segismont <tsegismo@redhat.com>
Date:   Wed Jun 5 10:57:29 2013 +0200

    Bug 970177 - Cannot browse the GUI while the plugin scan is running
    
    Moved two @Singleton beans concurrency management setting to type 'BEAN'. In both cases state is initialized on startup and is thread safe.
Comment 4 Heiko W. Rupp 2013-09-11 05:53:50 EDT
Bulk closing of old issues now that HRQ 4.9 is in front of the door.

If you think the issue has not been solved, then please open a new bug and mention this one in the description.

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