Bug 1340902

Summary: There is no limit on container images concurrent SSAs
Product: Red Hat CloudForms Management Engine Reporter: Mooli Tayer <mtayer>
Component: SmartState AnalysisAssignee: Mooli Tayer <mtayer>
Status: CLOSED ERRATA QA Contact: Einat Pacifici <epacific>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 5.6.0CC: cpelland, dron, epacific, fsimonce, jhardy, mfeifer, obarenbo, simaishi
Target Milestone: GAFlags: epacific: automate_bug+
Target Release: 5.6.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard: container
Fixed In Version: 5.6.0.9 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-06-29 16:06:52 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Mooli Tayer 2016-05-30 15:42:52 UTC
Description of problem:
vm SSA implements several different load factors based on resource e.g concurrent_per_ems, concurrent_per_host

Container Image scanning currently does not have this behavior and when a user defines a scheduled provider scan all images, what ever their number might be, are scanned simultaneously.

A large number of images will potentially cause a load issue on both the containers provider and the ems

Version-Release number of selected component (if applicable):
darga-1-rc1.1

How reproducible:
100%

Steps to Reproduce:
1. Select all images in the UI => Perform Smart State Analysis
2. Go to task => all vm & container analysis tasks

Actual results:
All jobs are started at once

Expected results:
The user should be able to define a load_factor. No more then load_factor ssa per on provider should be allowed to run simultaneously.

Additional info:

Comment 2 Mooli Tayer 2016-05-30 18:20:21 UTC
Fix suggested upstream: https://github.com/ManageIQ/manageiq/pull/8760

Comment 3 Mooli Tayer 2016-05-31 15:38:54 UTC
To verify this change on qe, two things must be verified:

1. The new limit on parallel execution of container image scans works as expected. At most 3 scans run together (run all and check out "All vm and container analysis tasks"). The number can be changed in the configuration
through container_scanning -> concurrent_per_ems

2. The scanning and concurrency of vms was not effected.

Comment 4 Einat Pacifici 2016-06-07 11:58:29 UTC
Verified. 
Steps to verify: 
Modified configuration in: container_scanning -> concurrent_per_ems
 (default was =3, changed it to =2)

Added 4 new apps in Openshift (each app used a new image)
Viewed Settings --> Tasks. 

Two new images were scanned at any one time. 
Once scan was completed, two new images were scanned.

Comment 5 Mooli Tayer 2016-06-07 15:49:21 UTC
Hi Einat, did you test vm scanning concurrency as well?
(See my previous comment) that would probably reuire some help

Comment 7 errata-xmlrpc 2016-06-29 16:06:52 UTC
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:1348