Commit e88fbc7
committed
fix: rename Resource.template field to uri_template
- Rename 'template' column to 'uri_template' in Resource model for clarity
- Add Alembic migration (191a2def08d7) to rename the column
- Update schemas (ResourceCreate, ResourceUpdate, ResourceRead) to use uri_template
- Add uri_template field to ResourceRead for API responses
- Fetch and store resource templates when registering MCP gateways
- Update URI validation pattern to allow curly braces {} for templates
- Fix read_resource to accept either resource_id or resource_uri
- Update ResourceTemplate model to use proper JSON alias (uriTemplate)
- Update all related tests to use new field name
Closes #1455
Signed-off-by: Mihai Criveti <[email protected]>1 parent ba35cdb commit e88fbc7
File tree
22 files changed
+911
-352
lines changed- charts/mcp-stack
- docs
- docs
- mcpgateway
- alembic/versions
- common
- services
- static
- transports
- tests
- e2e
- unit/mcpgateway
- services
- validation
22 files changed
+911
-352
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
349 | 349 | | |
350 | 350 | | |
351 | 351 | | |
352 | | - | |
| 352 | + | |
353 | 353 | | |
354 | 354 | | |
355 | 355 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1609 | 1609 | | |
1610 | 1610 | | |
1611 | 1611 | | |
1612 | | - | |
| 1612 | + | |
1613 | 1613 | | |
1614 | 1614 | | |
1615 | 1615 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1609 | 1609 | | |
1610 | 1610 | | |
1611 | 1611 | | |
1612 | | - | |
| 1612 | + | |
1613 | 1613 | | |
1614 | 1614 | | |
1615 | 1615 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7566 | 7566 | | |
7567 | 7567 | | |
7568 | 7568 | | |
7569 | | - | |
| 7569 | + | |
7570 | 7570 | | |
7571 | 7571 | | |
7572 | 7572 | | |
| |||
7599 | 7599 | | |
7600 | 7600 | | |
7601 | 7601 | | |
7602 | | - | |
| 7602 | + | |
| 7603 | + | |
7603 | 7604 | | |
| 7605 | + | |
| 7606 | + | |
| 7607 | + | |
| 7608 | + | |
| 7609 | + | |
| 7610 | + | |
7604 | 7611 | | |
7605 | 7612 | | |
7606 | 7613 | | |
7607 | 7614 | | |
7608 | 7615 | | |
7609 | 7616 | | |
7610 | | - | |
| 7617 | + | |
7611 | 7618 | | |
7612 | 7619 | | |
7613 | 7620 | | |
| |||
Lines changed: 45 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
31 | 31 | | |
32 | 32 | | |
33 | 33 | | |
34 | | - | |
| 34 | + | |
35 | 35 | | |
36 | 36 | | |
37 | 37 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
715 | 715 | | |
716 | 716 | | |
717 | 717 | | |
718 | | - | |
| 718 | + | |
| 719 | + | |
| 720 | + | |
| 721 | + | |
719 | 722 | | |
720 | 723 | | |
721 | 724 | | |
722 | | - | |
| 725 | + | |
723 | 726 | | |
724 | 727 | | |
725 | 728 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1303 | 1303 | | |
1304 | 1304 | | |
1305 | 1305 | | |
1306 | | - | |
| 1306 | + | |
1307 | 1307 | | |
1308 | 1308 | | |
1309 | 1309 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2161 | 2161 | | |
2162 | 2162 | | |
2163 | 2163 | | |
2164 | | - | |
| 2164 | + | |
2165 | 2165 | | |
2166 | 2166 | | |
2167 | 2167 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2865 | 2865 | | |
2866 | 2866 | | |
2867 | 2867 | | |
2868 | | - | |
| 2868 | + | |
2869 | 2869 | | |
2870 | 2870 | | |
2871 | 2871 | | |
| |||
0 commit comments