Skip to content

Commit f0b2c05

Browse files
committed
bump
1 parent 232bafa commit f0b2c05

File tree

3 files changed

+49
-33
lines changed

3 files changed

+49
-33
lines changed

.github/workflows/report.template.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ jobs:
2828
- name: setup node
2929
uses: actions/setup-node@v4
3030
with:
31-
node-version: 22
31+
node-version: 21
3232

3333
- name: install dependencies
3434
run: yarn install

federation-v1/gateways/cosmo/Dockerfile

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,22 +3,20 @@ FROM alpine:20240329
33
RUN apk --no-cache add curl
44

55
WORKDIR /home/gw
6-
COPY config.json ./
6+
COPY router.json ./
77

88
ENV ROUTER_VERSION=0.117.0
99

1010
RUN curl -L https://github.com/wundergraph/cosmo/releases/download/router%40${ROUTER_VERSION}/router-router@${ROUTER_VERSION}-linux-$(uname -m | sed s:aarch:arm:| sed s:x86_:amd:).tar.gz | gunzip -dc | tar x && mv router /usr/local/bin
1111

1212
ENV LOG_LEVEL=fatal
13-
ENV FEDERATED_GRAPH_NAME=federation
14-
ENV GRAPH_API_TOKEN=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwiZmVkZXJhdGVkX2dyYXBoX2lkIjoiSm9obiBEb2UiLCJvcmdhbml6YXRpb25faWQiOiJKb2huIERvZSJ9.l1h9MQUKZuVZ6KklemIfIh7AqCk8Pjed94c6VHk5VOU
1513
ENV LISTEN_ADDR=0.0.0.0:4000
1614
ENV TRACING_ENABLED=false
1715
ENV METRICS_ENABLED=false
1816
ENV METRICS_OTLP_ENABLED=false
1917
ENV GRAPHQL_METRICS_ENABLED=false
2018
ENV PROMETHEUS_ENABLED=false
21-
ENV ROUTER_CONFIG_PATH=config.json
19+
ENV ROUTER_CONFIG_PATH=router.json
2220

2321
EXPOSE 4000
2422

federation-v1/gateways/cosmo/config.json renamed to federation-v1/gateways/cosmo/router.json

Lines changed: 46 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -22,26 +22,29 @@
2222
},
2323
"subscription": {
2424
"enabled": true,
25-
"url": { "staticVariableContent": "http://accounts:4001/graphql" }
25+
"url": { "staticVariableContent": "http://accounts:4001/graphql" },
26+
"protocol": "GRAPHQL_SUBSCRIPTION_PROTOCOL_WS",
27+
"websocketSubprotocol": "GRAPHQL_WEBSOCKET_SUBPROTOCOL_AUTO"
2628
},
2729
"federation": {
2830
"enabled": true,
29-
"serviceSdl": "extend type Query {\n me: User\n user(id: ID!): User\n users: [User]\n}\n\ntype User @key(fields: \"id\") {\n id: ID!\n name: String\n username: String\n birthday: Int\n}\n\ndirective @include(if: Boolean!) on FIELD | FRAGMENT_SPREAD | INLINE_FRAGMENT\n\ndirective @skip(if: Boolean!) on FIELD | FRAGMENT_SPREAD | INLINE_FRAGMENT"
31+
"serviceSdl": "extend type Query {\n me: User\n user(id: ID!): User\n users: [User]\n}\n\ntype User @key(fields: \"id\") {\n id: ID!\n name: String\n username: String\n birthday: Int\n}\n\ndirective @include(if: Boolean!) on FIELD | FRAGMENT_SPREAD | INLINE_FRAGMENT\n\ndirective @skip(if: Boolean!) on FIELD | FRAGMENT_SPREAD | INLINE_FRAGMENT\n"
3032
},
3133
"upstreamSchema": {
32-
"key": "c2e480f6edc1b5c9dac001c3b73eba82222cf3c3"
34+
"key": "db37a1abd369d6fee0ca43d7134e3998f9feba01"
3335
}
3436
},
3537
"requestTimeoutSeconds": "10",
36-
"id": "http://accounts:4001/graphql",
38+
"id": "0",
3739
"keys": [{ "typeName": "User", "selectionSet": "id" }]
3840
},
3941
{
4042
"kind": "GRAPHQL",
4143
"rootNodes": [
4244
{
4345
"typeName": "Product",
44-
"fieldNames": ["inStock", "shippingEstimate", "upc"]
46+
"fieldNames": ["inStock", "shippingEstimate", "upc"],
47+
"externalFieldNames": ["upc", "weight", "price"]
4548
}
4649
],
4750
"overrideFieldPathFromAlias": true,
@@ -55,18 +58,20 @@
5558
},
5659
"subscription": {
5760
"enabled": true,
58-
"url": { "staticVariableContent": "http://inventory:4002/graphql" }
61+
"url": { "staticVariableContent": "http://inventory:4002/graphql" },
62+
"protocol": "GRAPHQL_SUBSCRIPTION_PROTOCOL_WS",
63+
"websocketSubprotocol": "GRAPHQL_WEBSOCKET_SUBPROTOCOL_AUTO"
5964
},
6065
"federation": {
6166
"enabled": true,
62-
"serviceSdl": "extend type Product @key(fields: \"upc\") {\n upc: String! @external\n weight: Int @external\n price: Int @external\n inStock: Boolean\n shippingEstimate: Int @requires(fields: \"price weight\")\n}\n\ndirective @include(if: Boolean!) on FIELD | FRAGMENT_SPREAD | INLINE_FRAGMENT\n\ndirective @skip(if: Boolean!) on FIELD | FRAGMENT_SPREAD | INLINE_FRAGMENT"
67+
"serviceSdl": "extend type Product @key(fields: \"upc\") {\n upc: String! @external\n weight: Int @external\n price: Int @external\n inStock: Boolean\n shippingEstimate: Int @requires(fields: \"price weight\")\n}\n\ndirective @include(if: Boolean!) on FIELD | FRAGMENT_SPREAD | INLINE_FRAGMENT\n\ndirective @skip(if: Boolean!) on FIELD | FRAGMENT_SPREAD | INLINE_FRAGMENT\n"
6368
},
6469
"upstreamSchema": {
65-
"key": "f7b11b1cff74e3cd6b2d8492d52a8f98b77b155d"
70+
"key": "64a29f293bb6d35526ce51e1715b8032cdfb31bf"
6671
}
6772
},
6873
"requestTimeoutSeconds": "10",
69-
"id": "http://inventory:4002/graphql",
74+
"id": "1",
7075
"keys": [{ "typeName": "Product", "selectionSet": "upc" }],
7176
"requires": [
7277
{
@@ -79,11 +84,11 @@
7984
{
8085
"kind": "GRAPHQL",
8186
"rootNodes": [
82-
{ "typeName": "Query", "fieldNames": ["topProducts"] },
8387
{
8488
"typeName": "Product",
8589
"fieldNames": ["upc", "name", "price", "weight"]
86-
}
90+
},
91+
{ "typeName": "Query", "fieldNames": ["topProducts"] }
8792
],
8893
"overrideFieldPathFromAlias": true,
8994
"customGraphql": {
@@ -96,28 +101,38 @@
96101
},
97102
"subscription": {
98103
"enabled": true,
99-
"url": { "staticVariableContent": "http://products:4003/graphql" }
104+
"url": { "staticVariableContent": "http://products:4003/graphql" },
105+
"protocol": "GRAPHQL_SUBSCRIPTION_PROTOCOL_WS",
106+
"websocketSubprotocol": "GRAPHQL_WEBSOCKET_SUBPROTOCOL_AUTO"
100107
},
101108
"federation": {
102109
"enabled": true,
103-
"serviceSdl": "type Product @key(fields: \"upc\") {\n upc: String!\n name: String\n price: Int\n weight: Int\n}\n\nextend type Query {\n topProducts(first: Int = 5): [Product]\n}\n\ndirective @include(if: Boolean!) on FIELD | FRAGMENT_SPREAD | INLINE_FRAGMENT\n\ndirective @skip(if: Boolean!) on FIELD | FRAGMENT_SPREAD | INLINE_FRAGMENT"
110+
"serviceSdl": "type Product @key(fields: \"upc\") {\n upc: String!\n name: String\n price: Int\n weight: Int\n}\n\nextend type Query {\n topProducts(first: Int = 5): [Product]\n}\n\ndirective @include(if: Boolean!) on FIELD | FRAGMENT_SPREAD | INLINE_FRAGMENT\n\ndirective @skip(if: Boolean!) on FIELD | FRAGMENT_SPREAD | INLINE_FRAGMENT\n"
104111
},
105112
"upstreamSchema": {
106-
"key": "bc383e3c6e7d1172a4ff9e785fe3958a08289d5f"
113+
"key": "1afef6ee5330df98b15899d48b7d738c0f43f429"
107114
}
108115
},
109116
"requestTimeoutSeconds": "10",
110-
"id": "http://products:4003/graphql",
117+
"id": "2",
111118
"keys": [{ "typeName": "Product", "selectionSet": "upc" }]
112119
},
113120
{
114121
"kind": "GRAPHQL",
115122
"rootNodes": [
116-
{ "typeName": "Product", "fieldNames": ["reviews", "upc"] },
117-
{ "typeName": "User", "fieldNames": ["reviews", "id"] },
123+
{
124+
"typeName": "Product",
125+
"fieldNames": ["reviews", "upc"],
126+
"externalFieldNames": ["upc"]
127+
},
118128
{
119129
"typeName": "Review",
120130
"fieldNames": ["id", "body", "product", "author"]
131+
},
132+
{
133+
"typeName": "User",
134+
"fieldNames": ["reviews", "id"],
135+
"externalFieldNames": ["id", "username"]
121136
}
122137
],
123138
"overrideFieldPathFromAlias": true,
@@ -131,22 +146,24 @@
131146
},
132147
"subscription": {
133148
"enabled": true,
134-
"url": { "staticVariableContent": "http://reviews:4004/graphql" }
149+
"url": { "staticVariableContent": "http://reviews:4004/graphql" },
150+
"protocol": "GRAPHQL_SUBSCRIPTION_PROTOCOL_WS",
151+
"websocketSubprotocol": "GRAPHQL_WEBSOCKET_SUBPROTOCOL_AUTO"
135152
},
136153
"federation": {
137154
"enabled": true,
138-
"serviceSdl": "extend type Product @key(fields: \"upc\") {\n upc: String! @external\n reviews: [Review]\n}\n\ntype Review @key(fields: \"id\") {\n id: ID!\n body: String\n product: Product\n author: User @provides(fields: \"username\")\n}\n\nextend type User @key(fields: \"id\") {\n id: ID! @external\n username: String @external\n reviews: [Review]\n}\n\ndirective @include(if: Boolean!) on FIELD | FRAGMENT_SPREAD | INLINE_FRAGMENT\n\ndirective @skip(if: Boolean!) on FIELD | FRAGMENT_SPREAD | INLINE_FRAGMENT"
155+
"serviceSdl": "extend type Product @key(fields: \"upc\") {\n upc: String! @external\n reviews: [Review]\n}\n\ntype Review @key(fields: \"id\") {\n id: ID!\n body: String\n product: Product\n author: User @provides(fields: \"username\")\n}\n\nextend type User @key(fields: \"id\") {\n id: ID! @external\n username: String @external\n reviews: [Review]\n}\n\ndirective @include(if: Boolean!) on FIELD | FRAGMENT_SPREAD | INLINE_FRAGMENT\n\ndirective @skip(if: Boolean!) on FIELD | FRAGMENT_SPREAD | INLINE_FRAGMENT\n"
139156
},
140157
"upstreamSchema": {
141-
"key": "b3067d38a59b838d3702985e3a302b725bcb4c2d"
158+
"key": "1b9a4a72484d26b758d37d3884812af6affbc02f"
142159
}
143160
},
144161
"requestTimeoutSeconds": "10",
145-
"id": "http://reviews:4004/graphql",
162+
"id": "3",
146163
"keys": [
147164
{ "typeName": "Product", "selectionSet": "upc" },
148-
{ "typeName": "User", "selectionSet": "id" },
149-
{ "typeName": "Review", "selectionSet": "id" }
165+
{ "typeName": "Review", "selectionSet": "id" },
166+
{ "typeName": "User", "selectionSet": "id" }
150167
],
151168
"provides": [
152169
{
@@ -173,14 +190,15 @@
173190
]
174191
}
175192
],
176-
"graphqlSchema": "directive @tag(name: String!) repeatable on ARGUMENT_DEFINITION | ENUM | ENUM_VALUE | FIELD_DEFINITION | INPUT_FIELD_DEFINITION | INPUT_OBJECT | INTERFACE | OBJECT | SCALAR | UNION\n\ntype User {\n id: ID!\n name: String\n username: String\n birthday: Int\n reviews: [Review]\n}\n\ntype Product {\n upc: String!\n name: String\n price: Int\n weight: Int\n inStock: Boolean\n shippingEstimate: Int\n reviews: [Review]\n}\n\ntype Review {\n id: ID!\n body: String\n product: Product\n author: User\n}\n\ntype Query {\n me: User\n user(id: ID!): User\n users: [User]\n topProducts(first: Int = 5): [Product]\n}",
193+
"graphqlSchema": "schema {\n query: Query\n}\n\ndirective @tag(name: String!) repeatable on ARGUMENT_DEFINITION | ENUM | ENUM_VALUE | FIELD_DEFINITION | INPUT_FIELD_DEFINITION | INPUT_OBJECT | INTERFACE | OBJECT | SCALAR | UNION\n\ntype Query {\n me: User\n user(id: ID!): User\n users: [User]\n topProducts(first: Int = 5): [Product]\n}\n\ntype User {\n id: ID!\n name: String\n username: String\n birthday: Int\n reviews: [Review]\n}\n\ntype Product {\n upc: String!\n weight: Int\n price: Int\n inStock: Boolean\n shippingEstimate: Int\n name: String\n reviews: [Review]\n}\n\ntype Review {\n id: ID!\n body: String\n product: Product\n author: User\n}",
177194
"stringStorage": {
178-
"c2e480f6edc1b5c9dac001c3b73eba82222cf3c3": "schema {\n query: Query\n}\n\ndirective @extends on INTERFACE | OBJECT\n\ndirective @external on FIELD_DEFINITION | OBJECT\n\ndirective @key(fields: openfed__FieldSet!, resolvable: Boolean = true) repeatable on OBJECT\n\ndirective @provides(fields: openfed__FieldSet!) on FIELD_DEFINITION\n\ndirective @requires(fields: openfed__FieldSet!) on FIELD_DEFINITION\n\ndirective @tag(name: String!) repeatable on ARGUMENT_DEFINITION | ENUM | ENUM_VALUE | FIELD_DEFINITION | INPUT_FIELD_DEFINITION | INPUT_OBJECT | INTERFACE | OBJECT | SCALAR | UNION\n\ntype Query {\n me: User\n user(id: ID!): User\n users: [User]\n}\n\ntype User @key(fields: \"id\") {\n birthday: Int\n id: ID!\n name: String\n username: String\n}\n\nscalar openfed__FieldSet",
179-
"f7b11b1cff74e3cd6b2d8492d52a8f98b77b155d": "directive @extends on INTERFACE | OBJECT\n\ndirective @external on FIELD_DEFINITION | OBJECT\n\ndirective @key(fields: openfed__FieldSet!, resolvable: Boolean = true) repeatable on OBJECT\n\ndirective @provides(fields: openfed__FieldSet!) on FIELD_DEFINITION\n\ndirective @requires(fields: openfed__FieldSet!) on FIELD_DEFINITION\n\ndirective @tag(name: String!) repeatable on ARGUMENT_DEFINITION | ENUM | ENUM_VALUE | FIELD_DEFINITION | INPUT_FIELD_DEFINITION | INPUT_OBJECT | INTERFACE | OBJECT | SCALAR | UNION\n\ntype Product @key(fields: \"upc\") {\n inStock: Boolean\n price: Int @external\n shippingEstimate: Int @requires(fields: \"price weight\")\n upc: String! @external\n weight: Int @external\n}\n\nscalar openfed__FieldSet",
180-
"bc383e3c6e7d1172a4ff9e785fe3958a08289d5f": "schema {\n query: Query\n}\n\ndirective @extends on INTERFACE | OBJECT\n\ndirective @external on FIELD_DEFINITION | OBJECT\n\ndirective @key(fields: openfed__FieldSet!, resolvable: Boolean = true) repeatable on OBJECT\n\ndirective @provides(fields: openfed__FieldSet!) on FIELD_DEFINITION\n\ndirective @requires(fields: openfed__FieldSet!) on FIELD_DEFINITION\n\ndirective @tag(name: String!) repeatable on ARGUMENT_DEFINITION | ENUM | ENUM_VALUE | FIELD_DEFINITION | INPUT_FIELD_DEFINITION | INPUT_OBJECT | INTERFACE | OBJECT | SCALAR | UNION\n\ntype Product @key(fields: \"upc\") {\n name: String\n price: Int\n upc: String!\n weight: Int\n}\n\ntype Query {\n topProducts(first: Int = 5): [Product]\n}\n\nscalar openfed__FieldSet",
181-
"b3067d38a59b838d3702985e3a302b725bcb4c2d": "directive @extends on INTERFACE | OBJECT\n\ndirective @external on FIELD_DEFINITION | OBJECT\n\ndirective @key(fields: openfed__FieldSet!, resolvable: Boolean = true) repeatable on OBJECT\n\ndirective @provides(fields: openfed__FieldSet!) on FIELD_DEFINITION\n\ndirective @requires(fields: openfed__FieldSet!) on FIELD_DEFINITION\n\ndirective @tag(name: String!) repeatable on ARGUMENT_DEFINITION | ENUM | ENUM_VALUE | FIELD_DEFINITION | INPUT_FIELD_DEFINITION | INPUT_OBJECT | INTERFACE | OBJECT | SCALAR | UNION\n\ntype Product @key(fields: \"upc\") {\n reviews: [Review]\n upc: String! @external\n}\n\ntype Review @key(fields: \"id\") {\n author: User @provides(fields: \"username\")\n body: String\n id: ID!\n product: Product\n}\n\ntype User @key(fields: \"id\") {\n id: ID! @external\n reviews: [Review]\n username: String @external\n}\n\nscalar openfed__FieldSet"
195+
"db37a1abd369d6fee0ca43d7134e3998f9feba01": "schema {\n query: Query\n}\n\ndirective @extends on INTERFACE | OBJECT\n\ndirective @external on FIELD_DEFINITION | OBJECT\n\ndirective @key(fields: openfed__FieldSet!, resolvable: Boolean = true) repeatable on INTERFACE | OBJECT\n\ndirective @provides(fields: openfed__FieldSet!) on FIELD_DEFINITION\n\ndirective @requires(fields: openfed__FieldSet!) on FIELD_DEFINITION\n\ndirective @tag(name: String!) repeatable on ARGUMENT_DEFINITION | ENUM | ENUM_VALUE | FIELD_DEFINITION | INPUT_FIELD_DEFINITION | INPUT_OBJECT | INTERFACE | OBJECT | SCALAR | UNION\n\ntype Query {\n me: User\n user(id: ID!): User\n users: [User]\n}\n\ntype User @key(fields: \"id\") {\n birthday: Int\n id: ID!\n name: String\n username: String\n}\n\nscalar openfed__FieldSet",
196+
"64a29f293bb6d35526ce51e1715b8032cdfb31bf": "directive @extends on INTERFACE | OBJECT\n\ndirective @external on FIELD_DEFINITION | OBJECT\n\ndirective @key(fields: openfed__FieldSet!, resolvable: Boolean = true) repeatable on INTERFACE | OBJECT\n\ndirective @provides(fields: openfed__FieldSet!) on FIELD_DEFINITION\n\ndirective @requires(fields: openfed__FieldSet!) on FIELD_DEFINITION\n\ndirective @tag(name: String!) repeatable on ARGUMENT_DEFINITION | ENUM | ENUM_VALUE | FIELD_DEFINITION | INPUT_FIELD_DEFINITION | INPUT_OBJECT | INTERFACE | OBJECT | SCALAR | UNION\n\ntype Product @key(fields: \"upc\") {\n inStock: Boolean\n price: Int @external\n shippingEstimate: Int @requires(fields: \"price weight\")\n upc: String! @external\n weight: Int @external\n}\n\nscalar openfed__FieldSet",
197+
"1afef6ee5330df98b15899d48b7d738c0f43f429": "schema {\n query: Query\n}\n\ndirective @extends on INTERFACE | OBJECT\n\ndirective @external on FIELD_DEFINITION | OBJECT\n\ndirective @key(fields: openfed__FieldSet!, resolvable: Boolean = true) repeatable on INTERFACE | OBJECT\n\ndirective @provides(fields: openfed__FieldSet!) on FIELD_DEFINITION\n\ndirective @requires(fields: openfed__FieldSet!) on FIELD_DEFINITION\n\ndirective @tag(name: String!) repeatable on ARGUMENT_DEFINITION | ENUM | ENUM_VALUE | FIELD_DEFINITION | INPUT_FIELD_DEFINITION | INPUT_OBJECT | INTERFACE | OBJECT | SCALAR | UNION\n\ntype Product @key(fields: \"upc\") {\n name: String\n price: Int\n upc: String!\n weight: Int\n}\n\ntype Query {\n topProducts(first: Int = 5): [Product]\n}\n\nscalar openfed__FieldSet",
198+
"1b9a4a72484d26b758d37d3884812af6affbc02f": "directive @extends on INTERFACE | OBJECT\n\ndirective @external on FIELD_DEFINITION | OBJECT\n\ndirective @key(fields: openfed__FieldSet!, resolvable: Boolean = true) repeatable on INTERFACE | OBJECT\n\ndirective @provides(fields: openfed__FieldSet!) on FIELD_DEFINITION\n\ndirective @requires(fields: openfed__FieldSet!) on FIELD_DEFINITION\n\ndirective @tag(name: String!) repeatable on ARGUMENT_DEFINITION | ENUM | ENUM_VALUE | FIELD_DEFINITION | INPUT_FIELD_DEFINITION | INPUT_OBJECT | INTERFACE | OBJECT | SCALAR | UNION\n\ntype Product @key(fields: \"upc\") {\n reviews: [Review]\n upc: String! @external\n}\n\ntype Review @key(fields: \"id\") {\n author: User @provides(fields: \"username\")\n body: String\n id: ID!\n product: Product\n}\n\ntype User @key(fields: \"id\") {\n id: ID! @external\n reviews: [Review]\n username: String @external\n}\n\nscalar openfed__FieldSet"
182199
}
183200
},
201+
"version": "6e9dbed6-ec25-44f1-8693-4d44274fe9a6",
184202
"subgraphs": [
185203
{
186204
"id": "0",

0 commit comments

Comments
 (0)