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

gloo edge could be upgraded to use the latest inja #8177

Closed
mrsathis opened this issue May 2, 2023 · 4 comments
Closed

gloo edge could be upgraded to use the latest inja #8177

mrsathis opened this issue May 2, 2023 · 4 comments
Assignees

Comments

@mrsathis
Copy link

mrsathis commented May 2, 2023

Version

1.14.x (latest stable)

Is your feature request related to a problem? Please describe.

Customer unable to use variables in inja template, and they claim that, as per inja documentation that they can define a variable by using 'set' keyword, and see that it works with inja if it run inja independently but when they use the template in edge, getting the below error:

Failed to parse response template: Failed to parse body template [inja.exception.parser_error] exp │
│ ected statement, got 'size'\n, error: exit status 1.

sample : '{% set size = 2 %}{ "completeDifferentResponse": "{{ name }} ││ -  {{ size }} Pastry Respomse Transformed"}'

Describe the solution you'd like

Customer would like to see, if gloo edge could be upgraded to use the latest inja.

Describe alternatives you've considered

No response

Additional Context

we have observed that the inja release version is 2.1.

@sam-heilbron
Copy link
Contributor

I've added the 1.14 release as a target for this work. We should still validate the riskiness of this change, and discuss how safe it is to backport @ben-taussig-solo

@nfuden
Copy link
Contributor

nfuden commented Jun 8, 2023

As a part of this effort we MUST validate what guard rails need to exist. Ie there are lots of new functions, which can crash envoy.

@jbohanon
Copy link
Contributor

One of the major issues in this upgrade is Inja's removal of JSON Pointer syntax support. Gloo Edge has supported configuring templates with JSON Pointer syntax for as long as it has been supporting transformations. I have opened pantor/inja#269 to request the re-introduction of JSON Pointer support.

This will block an Inja upgrade being backported to 1.14.

@jbohanon
Copy link
Contributor

This will be released in the following:
Gloo Edge 1.15.0-beta21
Gloo Edge Enterprise 1.15.0-beta5

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants