Commit 93ac819
committed
fix(api): use apiextensionsv1.JSON for Lua filterContext
Address review feedback on #8730:
- Change FilterContext field type from map[string]string to
*apiextensionsv1.JSON in both the API (lua_types.go) and IR (xds.go),
matching the existing pattern used by Wasm.Config and
DynamicModule.Config.
- Drop json/yaml struct tags from ir.Lua.FilterContext, consistent with
the other untagged fields on that struct.
- Update the xDS translator to unmarshal FilterContext.Raw into
structpb.Struct via protojson.Unmarshal, replacing the previous
string-only map iteration.
- Regenerate deepcopy, CRD manifests, and test fixtures.
Users can now pass non-string JSON values (numbers, bools, nested
objects) in filterContext without stringifying them.
Signed-off-by: Norman Stetter <85173861+norman-zon@users.noreply.github.com>1 parent ff6126e commit 93ac819
15 files changed
Lines changed: 60 additions & 55 deletions
File tree
- api/v1alpha1
- charts
- gateway-crds-helm/templates/generated
- gateway-helm/charts/crds/crds/generated
- internal
- gatewayapi/testdata
- ir
- xds/translator
- test/helm/gateway-crds-helm
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
8 | | - | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
9 | 12 | | |
10 | 13 | | |
11 | 14 | | |
| |||
45 | 48 | | |
46 | 49 | | |
47 | 50 | | |
48 | | - | |
49 | | - | |
50 | | - | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
51 | 55 | | |
52 | 56 | | |
53 | | - | |
| 57 | + | |
54 | 58 | | |
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 5 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1601 | 1601 | | |
1602 | 1602 | | |
1603 | 1603 | | |
1604 | | - | |
1605 | | - | |
1606 | 1604 | | |
1607 | | - | |
1608 | | - | |
1609 | | - | |
1610 | | - | |
| 1605 | + | |
| 1606 | + | |
| 1607 | + | |
| 1608 | + | |
| 1609 | + | |
1611 | 1610 | | |
1612 | 1611 | | |
1613 | 1612 | | |
| |||
Lines changed: 5 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1600 | 1600 | | |
1601 | 1601 | | |
1602 | 1602 | | |
1603 | | - | |
1604 | | - | |
1605 | 1603 | | |
1606 | | - | |
1607 | | - | |
1608 | | - | |
1609 | | - | |
| 1604 | + | |
| 1605 | + | |
| 1606 | + | |
| 1607 | + | |
| 1608 | + | |
1610 | 1609 | | |
1611 | 1610 | | |
1612 | 1611 | | |
| |||
Lines changed: 1 addition & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
215 | 215 | | |
216 | 216 | | |
217 | 217 | | |
| 218 | + | |
218 | 219 | | |
219 | 220 | | |
220 | 221 | | |
| |||
Lines changed: 1 addition & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
317 | 317 | | |
318 | 318 | | |
319 | 319 | | |
| 320 | + | |
320 | 321 | | |
321 | 322 | | |
322 | 323 | | |
| |||
Lines changed: 2 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
292 | 292 | | |
293 | 293 | | |
294 | 294 | | |
| 295 | + | |
295 | 296 | | |
296 | 297 | | |
297 | 298 | | |
| |||
327 | 328 | | |
328 | 329 | | |
329 | 330 | | |
| 331 | + | |
330 | 332 | | |
331 | 333 | | |
332 | 334 | | |
| |||
Lines changed: 6 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
466 | 466 | | |
467 | 467 | | |
468 | 468 | | |
| 469 | + | |
469 | 470 | | |
470 | 471 | | |
471 | 472 | | |
| |||
505 | 506 | | |
506 | 507 | | |
507 | 508 | | |
| 509 | + | |
508 | 510 | | |
509 | 511 | | |
510 | 512 | | |
| |||
544 | 546 | | |
545 | 547 | | |
546 | 548 | | |
| 549 | + | |
547 | 550 | | |
548 | 551 | | |
549 | 552 | | |
| |||
581 | 584 | | |
582 | 585 | | |
583 | 586 | | |
584 | | - | |
585 | | - | |
| 587 | + | |
586 | 588 | | |
| 589 | + | |
587 | 590 | | |
588 | 591 | | |
589 | 592 | | |
| |||
620 | 623 | | |
621 | 624 | | |
622 | 625 | | |
| 626 | + | |
623 | 627 | | |
624 | 628 | | |
625 | 629 | | |
| |||
Lines changed: 3 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
281 | 281 | | |
282 | 282 | | |
283 | 283 | | |
284 | | - | |
285 | | - | |
| 284 | + | |
286 | 285 | | |
287 | 286 | | |
| 287 | + | |
288 | 288 | | |
289 | 289 | | |
290 | 290 | | |
| |||
319 | 319 | | |
320 | 320 | | |
321 | 321 | | |
| 322 | + | |
322 | 323 | | |
323 | 324 | | |
324 | 325 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3685 | 3685 | | |
3686 | 3686 | | |
3687 | 3687 | | |
3688 | | - | |
3689 | | - | |
3690 | | - | |
| 3688 | + | |
| 3689 | + | |
| 3690 | + | |
3691 | 3691 | | |
3692 | 3692 | | |
3693 | 3693 | | |
| |||
0 commit comments