Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

eskip: do not add empty last route id to parse error #2875

Merged
merged 1 commit into from
Jan 19, 2024

Conversation

AlexanderYastrebov
Copy link
Member

@AlexanderYastrebov AlexanderYastrebov commented Jan 18, 2024

Follow up on #1885

@AlexanderYastrebov AlexanderYastrebov added minor no risk changes, for example new filters wip work in progress labels Jan 18, 2024
@AlexanderYastrebov AlexanderYastrebov removed the wip work in progress label Jan 18, 2024
Follow up on #1885

Signed-off-by: Alexander Yastrebov <[email protected]>
$$.route.id = $1.token
}

routeid:
symbol {
symbol colon {
// match symbol and colon to get route id early even if route parsing fails later
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there any performance improvement here?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, performance change is within measurement deviation

goos: linux
goarch: amd64
pkg: github.com/zalando/skipper/eskip
cpu: Intel(R) Core(TM) i5-8350U CPU @ 1.70GHz
                  │   HEAD~1    │                HEAD                │
                  │   sec/op    │   sec/op     vs base               │
ParsePredicates-8   8.189µ ± 4%   8.515µ ± 4%  +3.98% (p=0.007 n=10)
Parse-8             253.3m ± 2%   256.8m ± 3%  +1.38% (p=0.011 n=10)
geomean             1.440m        1.479m       +2.67%

                  │    HEAD~1    │                HEAD                 │
                  │     B/op     │     B/op      vs base               │
ParsePredicates-8   1.961Ki ± 0%   1.961Ki ± 0%       ~ (p=1.000 n=10)
Parse-8             49.02Mi ± 0%   49.02Mi ± 0%       ~ (p=0.566 n=10)
geomean             313.7Ki        313.7Ki       -0.00%

                  │   HEAD~1    │                 HEAD                 │
                  │  allocs/op  │  allocs/op   vs base                 │
ParsePredicates-8    32.00 ± 0%    32.00 ± 0%       ~ (p=1.000 n=10) ¹
Parse-8             1.080M ± 0%   1.080M ± 0%       ~ (p=0.700 n=10)
geomean             5.879k        5.879k       +0.00%
¹ all samples are equal

@MustafaSaber
Copy link
Member

👍

1 similar comment
@szuecs
Copy link
Member

szuecs commented Jan 19, 2024

👍

@szuecs szuecs merged commit 5c1a94f into master Jan 19, 2024
14 checks passed
@szuecs szuecs deleted the eskip/fix-last-route-id branch January 19, 2024 19:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
minor no risk changes, for example new filters
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants