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

skipper: improve createDataClients errors #3260

Merged
merged 1 commit into from
Oct 1, 2024

Conversation

AlexanderYastrebov
Copy link
Member

  • add context message to returned errors
  • remove duplicate logging - errors will be logged by the caller (main)

* add context message to returned errors
* remove duplicate logging - errors will be logged by the caller (main)

Signed-off-by: Alexander Yastrebov <[email protected]>
@AlexanderYastrebov AlexanderYastrebov added the minor no risk changes, for example new filters label Oct 1, 2024
@@ -1070,8 +1068,7 @@ func createDataClients(o Options, cr *certregistry.CertRegistry) ([]routing.Data
if o.InlineRoutes != "" {
ir, err := routestring.New(o.InlineRoutes)
if err != nil {
log.Error("error while parsing inline routes", err)
Copy link
Member Author

Choose a reason for hiding this comment

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

This log was also missing whitespace:

$ ./bin/skipper -inline-routes='* -> '
[APP]INFO[0000] Expose metrics in codahale format            
[APP]ERRO[0000] error while parsing inline routesparse failed after token ->, position 5: syntax error 
[APP]FATA[0000] parse failed after token ->, position 5: syntax error

@szuecs
Copy link
Member

szuecs commented Oct 1, 2024

👍

1 similar comment
@AlexanderYastrebov
Copy link
Member Author

👍

@AlexanderYastrebov AlexanderYastrebov merged commit 8f93ccd into master Oct 1, 2024
14 checks passed
@AlexanderYastrebov AlexanderYastrebov deleted the skipper/createDataClients-error branch October 1, 2024 20:35
RomanZavodskikh pushed a commit to zalando-incubator/kubernetes-on-aws that referenced this pull request Oct 8, 2024
Pushpalanka pushed a commit that referenced this pull request Oct 11, 2024
* add context message to returned errors
* remove duplicate logging - errors will be logged by the caller (main)

Signed-off-by: Alexander Yastrebov <[email protected]>
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.

2 participants