Skip to content
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

No option to disable Cost Analyzer #7679

Open
johan-lindqvist opened this issue Nov 4, 2024 · 2 comments
Open

No option to disable Cost Analyzer #7679

johan-lindqvist opened this issue Nov 4, 2024 · 2 comments
Labels
🌶️ hot chocolate ❓ question This issue is a question about feature of Hot Chocolate.

Comments

@johan-lindqvist
Copy link
Contributor

Product

Hot Chocolate

Version

14

Link to minimal reproduction

N/A

Steps to reproduce

We're using the AddGraphQLFunction() extension method in our project which in turn calls

but there's no option to configure if I want to disable the default security exposed through the AddGraphQLFunction() extension method.

Some way to override the cost analyzer and disable it would be nice since we don't have any use for the cost directives.

What is expected?

The option to disable cost analyzer exists

What is actually happening?

No option to disable the cost analyzer exists

Relevant log output

No response

Additional context

No response

@aidy-jenkins
Copy link
Contributor

Does this not have the desired effect?

services
   .AddGraphQLServer(...)
   .ModifyCostOptions(options => options.EnforceCostLimits = false)

@michaelstaib michaelstaib added the ❓ question This issue is a question about feature of Hot Chocolate. label Nov 5, 2024
@johan-lindqvist
Copy link
Contributor Author

Does this not have the desired effect?

services
.AddGraphQLServer(...)
.ModifyCostOptions(options => options.EnforceCostLimits = false)

The schema still has @cost on all the mutations and queries even with this code.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🌶️ hot chocolate ❓ question This issue is a question about feature of Hot Chocolate.
Projects
None yet
Development

No branches or pull requests

3 participants