Bug 1938922 - Router HAProxy config file template is slow to render due to repetitive regex compilations
Summary: Router HAProxy config file template is slow to render due to repetitive regex...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Routing
Version: 3.11.0
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: ---
: 4.6.z
Assignee: Andrew McDermott
QA Contact: Arvind iyengar
URL:
Whiteboard:
Depends On: 1938921
Blocks: 1938923
TreeView+ depends on / blocked
 
Reported: 2021-03-15 08:29 UTC by OpenShift BugZilla Robot
Modified: 2021-04-20 19:27 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2021-04-20 19:27:19 UTC
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github openshift router pull 270 0 None open [release-4.6] Bug 1938922: router/template: Cache compiled regular expressions 2021-03-16 17:06:47 UTC
Red Hat Product Errata RHBA-2021:1153 0 None None None 2021-04-20 19:27:38 UTC

Comment 3 Arvind iyengar 2021-03-29 09:10:34 UTC
Verified in "4.6.0-0.nightly-2021-03-26-015331" release version. With this payload, it is observed that the haproxy template rendition continuous to happen under sub-seconds times during constant load of generating 5k routes at a time. As noted below, the time hovered closed to 800ms consistently with no notable spikes beyond it: 
------
oc get clusterversion                       
NAME      VERSION                             AVAILABLE   PROGRESSING   SINCE   STATUS
version   4.6.0-0.nightly-2021-03-26-015331   True        False         156m    Cluster version is 4.6.0-0.nightly-2021-03-26-015331

oc get route | wc -l                     
5001

I0329 08:05:48.933878       1 router.go:449] template "msg"="writeConfig"  "duration"="894.941038ms"
I0329 08:05:53.777570       1 router.go:449] template "msg"="writeConfig"  "duration"="738.559017ms"
I0329 08:05:59.153738       1 router.go:449] template "msg"="writeConfig"  "duration"="1.114624645s"
I0329 08:06:03.867560       1 router.go:449] template "msg"="writeConfig"  "duration"="828.339329ms"
I0329 08:06:08.794525       1 router.go:449] template "msg"="writeConfig"  "duration"="755.20271ms"
I0329 08:06:13.776496       1 router.go:449] template "msg"="writeConfig"  "duration"="737.090098ms"
I0329 08:06:18.854449       1 router.go:449] template "msg"="writeConfig"  "duration"="814.947082ms"
------

Comment 8 errata-xmlrpc 2021-04-20 19:27:19 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 (OpenShift Container Platform 4.6.25 bug fix update), 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-2021:1153


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