Bug 1201428 - Concurrency of dynflow is bottlenecked at a single process
Summary: Concurrency of dynflow is bottlenecked at a single process
Keywords:
Status: CLOSED DEFERRED
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Tasks Plugin
Version: 6.1.0
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: Unspecified
Assignee: Ivan Necas
QA Contact: Katello QA List
URL: http://projects.theforeman.org/issues...
Whiteboard:
: 1264862 (view as bug list)
Depends On:
Blocks: 1122832 1264862
TreeView+ depends on / blocked
 
Reported: 2015-03-12 17:00 UTC by Alex Krzos
Modified: 2019-09-26 13:53 UTC (History)
8 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-03-20 16:17:52 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
dynflow_executor cpu usage from pidstat during 8, 6, 2 repo syncs (245.17 KB, image/png)
2015-03-12 17:00 UTC, Alex Krzos
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Foreman Issue Tracker 10962 0 Normal Closed Concurrency of dynflow is bottlenecked at a single process 2020-12-03 09:39:14 UTC
Foreman Issue Tracker 14806 0 Normal Closed Add option to set the amount of dynflow executors to be running 2020-12-03 09:39:15 UTC

Description Alex Krzos 2015-03-12 17:00:51 UTC
Created attachment 1001134 [details]
dynflow_executor cpu usage from pidstat during 8, 6, 2 repo syncs

Description of problem:
Dynflow is a single process within Satellite 6/6.1 and can bottleneck other concurrent tasks.


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

How reproducible:
100%

Steps to Reproduce:
1. Sync 2 equal sized repos concurrently and time
2. Sync 4 equal sized repos concurrently and time
3. Observe that hardware is not a bottleneck and that dynflow is consuming more and more cpu time at the end of the concurrent tasks.
4. Observe that dynflow_executor is limited to 1 process and a single cpu resource during concurrent tasks
5. With no hardware bottlenecks, observe increase in sync timing

Actual results:
Dynflow can be a source of additional latency on concurrent tasks.

Expected results:
dynflow_executor to scale as more concurrent tasks are conducted such that it does not bottleneck any other tasks.  It is also important that dynflow is not allowed to scale to the point where it uses all the system resources as well. 

Additional info:
Attached graphs shows cpu usage of dynflow_executor during syncs.
top graph = dynflow_excutor cpu usage during 8 repo syncs
middle graph = dynflow_excutor cpu usage during 6 repo syncs
bottom graph = dynflow_excutor cpu usage during 2 repo syncs



The average timing values for the syncs are:
2 repos - 142.15
4 repos - 204.83
6 repos - 259.62
8 repos - 317.05

The growth in overall timing was measured from hammer cli command to sync each repository.  The above values come from RHEL 6.6

Comment 1 RHEL Program Management 2015-03-12 17:03:31 UTC
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 3 Ivan Necas 2015-03-16 11:25:50 UTC
The limitation should be removed when getting this pr in (+ updating the configuration accordingly, to spawn multiple processors). This would workaround the GIL by running multiple independent Ruby processes. The ultimate solution would be switching to JRuby, but that's too far and can't be solved just in dynflow itself (which could be ready for JRuby in following weeks, also as part of the PR).

The 6.2 is good estimate for this limitation to be fixed by the multi-executors approach

Comment 4 Ivan Necas 2015-06-30 19:03:49 UTC
Created redmine issue http://projects.theforeman.org/issues/10962 from this bug

Comment 5 Bryan Kearney 2015-08-25 18:34:20 UTC
Upstream bug component is Tasks Plugin

Comment 6 Bryan Kearney 2015-08-31 08:03:14 UTC
Moving to POST since upstream bug http://projects.theforeman.org/issues/10962 has been closed

Comment 8 Ivan Necas 2016-03-18 13:42:37 UTC
switching to assigned, as we still miss the configuration pieces.

Comment 16 Peter Vreman 2016-08-29 07:41:28 UTC
*** Bug 1264862 has been marked as a duplicate of this bug. ***

Comment 17 Bryan Kearney 2017-03-20 16:17:52 UTC
This bug has an upstream issue. When this issue is resolved, it will be included in the next Satellite release. We will no longer be tracking this downstream. If you feel this should not have been closed, please feel free to re-open with additional details.


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