Project

General

Profile

Bug #24271

Edit Host as non-admin user is orders of magnitudes slower than as admin user

Added by Kavita Gaikwad about 1 year ago. Updated 9 months ago.

Status:
Closed
Priority:
High
Category:
Inventory
Target version:
-
Difficulty:
Triaged:
No
Bugzilla link:
Fixed in Releases:
Found in Releases:

Description

Cloned from https://bugzilla.redhat.com/show_bug.cgi?id=1598855

Description of problem:

Editing a host in the Satellite GUI takes significantly longer as a non-admin user than as an admin-user.

From the customer's data, as a non-admin user the /host/<hostid>/edit command takes 55 seconds and as the admin user, this command takes 4.713 seconds.

On our internal reproducer, the non-admin user editing /host/<hostid>/edit command takes 21.10 socends versus 1.89 seconds as the admin user.

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

Satellite 6.3.1.1+hotfixes

How reproducible:

Every time. Internal reproducer available.

Steps to Reproduce:
1. See private comment due to internal hostnames.

Associated revisions

Revision 7663c04b (diff)
Added by Kavita Gaikwad 9 months ago

Fixes #24271 - Edit Host as non-admin is slower than admin

For non-admin users, it takes more time in processing
common_parameters partials as comparative to admin.
Removed '.can?' method calls for checking edit & destroy
permissions on parameters and pre-calculated these permissions.

Revision 515cc445 (diff)
Added by Kavita Gaikwad 9 months ago

Refs #24271 - commit 2 with slower query change

Revision c73ee134 (diff)
Added by Kavita Gaikwad 9 months ago

Refs #24271 - extracted user check outside of authorizer

Revision fb1a2b10 (diff)
Added by Kavita Gaikwad 9 months ago

Refs #24271 - declared params_authorizer in partial than helper

Revision 17d37c9b (diff)
Added by Kavita Gaikwad 9 months ago

Refs #24271 - used param_authorizer as a local variable

History

#1 Updated by The Foreman Bot about 1 year ago

  • Status changed from New to Ready For Testing
  • Pull request https://github.com/theforeman/foreman/pull/5994 added

#2 Updated by Tomer Brisker 9 months ago

  • Assignee set to Kavita Gaikwad
  • Fixed in Releases 1.21.0 added

#3 Updated by Kavita Gaikwad 9 months ago

  • Status changed from Ready For Testing to Closed

Also available in: Atom PDF