-
-
Notifications
You must be signed in to change notification settings - Fork 756
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
Update persisted-queries.md #3616
Conversation
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.
Thanks for chiming in and documenting persisted queries! ❤️
I've left some feedback for you below.
Updates related to Tobias start structure notes
@damikun sorry for the wait. I have put that on my stack now :) |
Small updates to header content...
Any plans on this or points that I can rewrite? :) |
@damikun just looked at it yesterday and merge main back in so that it is technically mergeable. |
.AddReadOnlyFileSystemQueryStorage("./persisted_queries"); | ||
} | ||
``` | ||
|
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.
Let's add another section here to show how to add the security aspect and limit the server to only allow persisted queries. I will post you some code examples.
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.
Are you able to throw in an example @michaelstaib ? Thre's a TODO spot just lower. Then I think we can merge this. It'll be helpful for us at AutoGuru too, as this is next on our list for persisted queries now that we've got them all setup for the perf side of things.
I'm also going to take a look! |
@tobias-tengler yes and no :D we should handle it, further we should be able to handle multiple of them. So if multiple are in the folder we should handle them as well. Lets create an issue for that and work details out on there. |
Good rewrite Tobias... You are good in understanding and writing Doc it will be better if you finish it.. |
8ed0478
to
c6a8f80
Compare
Any reason why this was retargeted to develop, while being added to the 11.3 milestone? There aren't any preview features being documented here. I think it can go straight into main... |
.UsePersistedQueryPipeline() | ||
// ... | ||
.UseRequest<BlockRegularQueriesMiddleware>(); |
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.
This is more complex than this ... you actually need to copy the full pipeline and hook into a specific place of the chain. While in your case you would still get the execution the regular request was already executed at this point.
This is why I moved this to develop so that we can introduce a new option that handles this.
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.
I have most of it implemented...I will revisit it later today
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.
Ah I see, works for me :)
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.
@michaelstaib what's the status of this? Should we track it as an issue?
I would like to get these docs in for the v11 guys: is there a good (albeit probably verbose) way to restrict execution to only persisted queries without the proposed option? If there is, I'd like to document it here and then merge it. We can then revisit the documentation, once the proposed option has been implemented in >= v12.
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.
@michaelstaib I extracted this as an issue so we do not loose track of it: #3943
Kudos, SonarCloud Quality Gate passed! |
Notes for StrawberryShake setup with persisted queries
3.3 caused me issues. @tobias-tengler , not sure if you have started this anywhere, but here's my scribbles from my investigations today. |
@benmccallum I won't cover this in this PR, but I derived an issue from your comment. |
I will merge this one an we can refine in follow-up prs. |
Adds persisted-queries documenattion
Related converetr pull-req repo: ChilliCream/hotchocolate-examples#31