-
Notifications
You must be signed in to change notification settings - Fork 216
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(jit): nested resolver handling (#2338)
Co-authored-by: Tushar Mathur <[email protected]> Co-authored-by: Shashi Kant <[email protected]>
- Loading branch information
1 parent
92455fd
commit b55acbf
Showing
20 changed files
with
834 additions
and
3,198 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
31 changes: 28 additions & 3 deletions
31
...hots/tailcall__core__generator__generator__test__should_generate_config_from_configs.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,31 +1,56 @@ | ||
--- | ||
source: src/core/generator/generator.rs | ||
expression: cfg_module.config.to_sdl() | ||
expression: cfg_module.config().to_sdl() | ||
--- | ||
schema @server(hostname: "0.0.0.0", port: 8000) @upstream(baseURL: "http://jsonplaceholder.typicode.com", httpCache: 42) { | ||
query: Query | ||
} | ||
|
||
type Album { | ||
id: Int! | ||
photos: [Photo] @http(path: "/albums/{{.value.id}}/photos?_limit=3") | ||
title: Int | ||
userId: Int! | ||
} | ||
|
||
type Comment { | ||
body: String! | ||
email: String! | ||
id: Int! | ||
name: String! | ||
title: String! @expr(body: "{{.value.email}}: {{.value.name}}") | ||
} | ||
|
||
type Photo { | ||
albumId: Int! | ||
combinedId: String! @expr(body: "Album: {{.value.albumId}}, photo: {{.value.id}}") | ||
id: Int! | ||
title: String! | ||
} | ||
|
||
type Post { | ||
body: String! | ||
comments: [Comment] @http(path: "/posts/{{.value.id}}/comments") | ||
id: Int! | ||
title: String! | ||
user: User @http(path: "/users/{{.value.userId}}") | ||
userId: Int! | ||
users: [User] @http(path: "/users") | ||
} | ||
|
||
type Query { | ||
post(id: Int!): Post @http(path: "/posts/{{.args.id}}") | ||
posts: [Post] @http(path: "/posts") | ||
posts: [Post] @http(path: "/posts?_limit=11") | ||
user(id: Int!): User @http(path: "/users/{{.args.id}}") | ||
users: [User] @http(path: "/users") | ||
} | ||
|
||
type User { | ||
albums: [Album] @http(path: "/users/{{.value.id}}/albums?_limit=2") | ||
blog: String @expr(body: "https://test.blog/users/website/{{.value.username}}") | ||
email: String! | ||
id: Int! | ||
name: String! | ||
phone: String | ||
username: String! | ||
website: String @expr(body: "/users/website/{{.value.username}}") | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
b55acbf
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Running 30s test @ http://localhost:8000/graphql
4 threads and 100 connections
413667 requests in 30.01s, 2.07GB read
Requests/sec: 13785.05
Transfer/sec: 70.75MB