Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 1231369 - Slow UI Response Time on Content View Page viewing published versions
Slow UI Response Time on Content View Page viewing published versions
Status: CLOSED ERRATA
Product: Red Hat Satellite 6
Classification: Red Hat
Component: Performance (Show other bugs)
6.1.0
Unspecified Unspecified
unspecified Severity high (vote)
: 6.2.2
: Unused
Assigned To: Chris Duryee
jcallaha
: Triaged
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2015-06-12 16:22 EDT by Alex Krzos
Modified: 2017-08-11 05:22 EDT (History)
10 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2016-09-14 17:02:56 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)
production.log snippet with foreman debug on (93.00 KB, application/zip)
2015-06-12 16:22 EDT, Alex Krzos
no flags Details


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Knowledge Base (Solution) 2041003 None None None Never
Red Hat Product Errata RHBA-2016:1885 normal SHIPPED_LIVE Satellite 6.2.2 bug fix update 2016-09-14 20:57:56 EDT

  None (edit)
Description Alex Krzos 2015-06-12 16:22:45 EDT
Created attachment 1038140 [details]
production.log snippet with foreman debug on

Description of problem:
Created several content views and published one more than 200 times.  When attempting to view this page and see all of the versions published the UI is very slow to respond.  In my environment the page load required more than 149s.  The page does display a spinner however I think we can do way better on rendering a page or at least paginate the version to reduce the load time.

Version-Release number of selected component (if applicable):
Satellite 6.1 GA SNAP2

How reproducible:
Always in this environment

Steps to Reproduce:
1. Create Content-View and publish many versions ( > 200)
2.
3.

Actual results:
2015-06-12 16:03:03 [I] Processing by Katello::Api::V2::ContentViewsController#show as JSON
2015-06-12 16:03:03 [I]   Parameters: {"organization_id"=>"1", "api_version"=>"v2", "id"=>"2"}
2015-06-12 16:03:03 [I]   Rendered /opt/rh/ruby193/root/usr/share/gems/gems/katello-2.2.0.38/app/views/katello/api/v2/content_views/show.json.rabl within katello/api/v2/layouts/resource (387.4ms)
2015-06-12 16:03:03 [I] Completed 200 OK in 393ms (Views: 317.4ms | ActiveRecord: 71.4ms)
2015-06-12 16:03:03 [I] Processing by Katello::Api::V2::ContentViewVersionsController#index as JSON
2015-06-12 16:03:03 [I]   Parameters: {"content_view_id"=>"2", "full_result"=>"true", "api_version"=>"v2"}
2015-06-12 16:05:33 [I]   Rendered /opt/rh/ruby193/root/usr/share/gems/gems/katello-2.2.0.38/app/views/katello/api/v2/content_view_versions/index.json.rabl within katello/api/v2/layouts/index (149606.6ms)
2015-06-12 16:05:33 [I] Completed 200 OK in 149855ms (Views: 42539.1ms | ActiveRecord: 107304.1ms)

Expected results:
< 3s loading time 

Additional info:

$ grep "select" -i production.log -c
4004
$ grep "cache" -i production.log -c
647
$ grep "completed" -i production.log
2015-06-12 16:14:43 [I] Completed 200 OK in 1347ms (Views: 1243.9ms | ActiveRecord: 85.7ms)
2015-06-12 16:17:11 [I] Completed 200 OK in 149372ms (Views: 41691.1ms | ActiveRecord: 107671.9ms)

Note the amount of time spent in ActiveRecord and number of queries.
Comment 1 RHEL Product and Program Management 2015-06-12 16:42:31 EDT
Since this issue was entered in Red Hat Bugzilla, the release flag has been
set to ? to ensure that it is properly evaluated for this release.
Comment 7 Chris Duryee 2016-08-18 11:43:50 EDT
I tested this on 6.2.0 via the following:

* create a CV
* for x in `seq 1 100`; do hammer --username admin --password changeme content-view publish --id 2; done

After creating 100+ content views, the content_views/2/versions page still loaded in 4.4 sec for me. Additionally, it did not seem to slow down as new versions were published.

moving to ON_QA.

QE note: the original expected behavior in the bug report was less than 3 sec. I get 4 seconds and sometimes up to 8 depending on system load, but it is still better than 149 sec.
Comment 8 jcallaha 2016-09-09 17:22:52 EDT
Verified in Satellite 6.2.2 Snap 1.1

created multiple content views with varying levels of content (one more than 50,000+ packages and 50 puppet repos). Test content view had 205 versions.

2016-09-09 17:20:24 [app] [I] Completed 200 OK in 359ms (Views: 243.4ms | ActiveRecord: 41.3ms)
2016-09-09 17:20:27 [app] [I]   Rendered /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.0.0.78/app/views/katello/api/v2/content_view_versions/index.json.rabl within katello/api/v2/layouts/collection (2780.2ms)
2016-09-09 17:20:27 [app] [I] Completed 200 OK in 2797ms (Views: 2681.5ms | ActiveRecord: 106.3ms)
Comment 10 errata-xmlrpc 2016-09-14 17:02:56 EDT
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2016:1885

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