Project

General

Profile

Bug #9869

Compliance on all reports is always computed, even when not necessary

Added by Nicolas CHARLES 11 months ago. Updated 9 months ago.

Status:
Released
Priority:
N/A
Category:
Performance and scalability
Target version:
Target version (plugin):
Severity:
User visibility:
Effort required:
Priority:

Description

Class ComplianceLevel always computes compliance at instantiation; and a lot of them can be created (there is one per rapport, plus one per component, plus one per directive, plus one per rule, time the number of nodes)
This computation is by itself not that time consuming ( 11 division, and BugDecimal toDouble), but it adds up to a lot of unecessary computation, especially when object are then thrown away

Converting it all to lazy yields minimal improvement in 3.1 (between 5 to 30% improvement for compliance computations), and dramatic improvement in 4.0 (HomePage goes from 4s when 1000 nodes updated their promises to 1 s)


Related issues

Duplicated by Rudder - Bug #9864: getNodeStatusReports is called for each node, and is slow to compute PolicyMode Inconsistency Rejected 2016-12-28

Associated revisions

Revision 8982bce4
Added by Nicolas CHARLES 11 months ago

Fixes #9869: Compliance on all reports is always computed, even when not necessary

History

#1 Updated by Nicolas CHARLES 11 months ago

  • Status changed from New to In progress

#2 Updated by Nicolas CHARLES 11 months ago

  • Status changed from In progress to Pending technical review
  • Assignee changed from Nicolas CHARLES to Vincent MEMBRÉ
  • Pull Request set to https://github.com/Normation/rudder/pull/1413

#3 Updated by Nicolas CHARLES 11 months ago

  • Status changed from Pending technical review to Pending release
  • % Done changed from 0 to 100

#4 Updated by Nicolas CHARLES 11 months ago

  • Duplicated by Bug #9864: getNodeStatusReports is called for each node, and is slow to compute PolicyMode Inconsistency added

#5 Updated by Vincent MEMBRÉ 9 months ago

  • Status changed from Pending release to Released

This bug has been fixed in Rudder 3.1.18, 3.2.11, 4.0.3 and 4.1.0~beta3 which were released today.

Also available in: Atom PDF