Project

General

Profile

Bug #7972

API call to get the list of node is REALLY slow with latest version

Added by Nicolas CHARLES about 5 years ago. Updated over 4 years ago.

Status:
Released
Priority:
1
Category:
API
Target version:
Severity:
User visibility:
Effort required:
Priority:
Tags:

Description

Calling API https://rudder.example.com/rudder/api/latest/nodes is super slow : 15s with 350 nodes
Same call with https://rudder.example.com/rudder/api/4/nodes is only 0,2s

We probably broke something in the latest version

Targetting to 3.0, but I'm not sure of the actual version of latest that is slower


Subtasks

Bug #8333: Missing methods in inventory code to efficiently query softwareReleasedVincent MEMBRÉ2016-05-19Actions
#1

Updated by Vincent MEMBRÉ about 5 years ago

  • Target version changed from 3.0.14 to 3.0.15
#2

Updated by Nicolas CHARLES almost 5 years ago

  • Tags set to sponsored
  • Priority changed from N/A to 1
#3

Updated by Vincent MEMBRÉ almost 5 years ago

  • Target version changed from 3.0.15 to 3.0.16
#4

Updated by Jonathan CLARKE almost 5 years ago

  • Assignee changed from Vincent MEMBRÉ to François ARMAND

François can you take this and figure out a solution please?

#5

Updated by François ARMAND almost 5 years ago

I can't reproduce that one. I have a test machine with ~2000 nodes, and both are extremelly fast.

Have you more information about the environment where the problem happens?

#6

Updated by François ARMAND almost 5 years ago

On an other (more realistic) rudder instance, we have a little difference.

- full lastest (api v6):
time curl -k -H "X-API-Token: ...." -X GET 'https://otherrudder/api/latest/nodes'
0,02s user 0,00s system 1% cpu 0,970 total

- only what was reported in previous api:
time curl -k -H "X-API-Token: ...." -X GET 'https://otherrudder/api/latest/nodes'?include=minimal
0,02s user 0,01s system 2% cpu 0,863 total

- api v5:
time curl -k -H "X-API-Token: ...." -X GET 'https://otherrudder/api/5/nodes'?include=minimal
0,01s user 0,01s system 9% cpu 0,255 total

This is of course higly non-scientific, because data with one try... But we can clearly see a 4x in total time, between API v5 and api v6 (between the two api v6 call, we can guess it's just because there is so much more data returned).

#7

Updated by François ARMAND almost 5 years ago

  • Status changed from New to In progress
#8

Updated by François ARMAND almost 5 years ago

  • Target version changed from 3.0.16 to 3.1.10

The slower one must be v6, since v5 didn't change anything on that.

#9

Updated by François ARMAND almost 5 years ago

  • Status changed from In progress to Pending technical review
  • Assignee changed from François ARMAND to Vincent MEMBRÉ
  • Pull Request set to https://github.com/Normation/rudder/pull/1098
#10

Updated by François ARMAND almost 5 years ago

  • Status changed from Pending technical review to Pending release
#11

Updated by Vincent MEMBRÉ over 4 years ago

  • Status changed from Pending release to Released

This bug has been fixed in Rudder 3.1.10 and 3.2.3 which were released on 2016-06-01, but not announced.

Also available in: Atom PDF