-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Upgrade graphql to 7.7.2 #15129
Merged
Merged
Upgrade graphql to 7.7.2 #15129
Changes from all commits
Commits
Show all changes
44 commits
Select commit
Hold shift + click to select a range
064cd9a
Upgrade to GraphQL 7.2.2
hishamco c3c2d82
Add media filenames on MediaFieldType
hyzx86 4cdec82
merge latest code
hyzx86 6998b7b
add logs to unit tests
hyzx86 eb287b3
merge test log function
hyzx86 acfa5ce
UseNLogHost()
hyzx86 32d8af3
restore changes
hyzx86 7d8674b
update test log
hyzx86 681dc52
fix LockedAsyncFieldResolver
hyzx86 9d71c8b
try upgrade graphql 7.7.2
hyzx86 6bc4238
Merge branch 'main' into upgrade-graphQL
hishamco 5007446
try remove all schema.RegisterType()
hyzx86 53d0e91
Merge branch 'upgrade-graphQL' of https://github.com/hyzx86/OrchardCo…
hyzx86 2349912
update dynamic field
hyzx86 43e28bf
update MenuItemInterface
hyzx86 937c818
Merge remote-tracking branch 'origin/main' into upgrade-graphQL
a8b36e2
fix LuceneQueryFieldTypeProvider
b5d0338
Merge branch 'main' into upgrade-graphQL
hishamco c8e4062
add types cache
f114d76
Merge branch 'upgrade-graphQL' of https://github.com/hyzx86/OrchardCo…
6701ff0
try cache types
hyzx86 4afb0d2
search type from di
hyzx86 056120b
add log details
5e29e7d
Operation is not valid due to the current state of the object.
hyzx86 5eb2356
merge main
hyzx86 7e565c3
merge main
hyzx86 571b933
AutoroutePart Filter not work
hyzx86 a8b2adb
merge main
hyzx86 eb0b164
Merge branch 'main' into upgrade-graphQL
hyzx86 9d93d5c
Fix all unit test
hyzx86 74f8d8f
Merge branch 'upgrade-graphQL' of https://github.com/hyzx86/OrchardCo…
hyzx86 d0e949b
Merge branch 'main' into upgrade-graphQL
hyzx86 0851741
merge main
hyzx86 8b996b3
fix error
hyzx86 9b70bae
Merge branch 'upgrade-graphQL' of https://github.com/hyzx86/OrchardCo…
hyzx86 6a601a5
add function ResolveContentItems in unit test
6c18b6b
remove log in test
ba5f95c
remove log in test
8ae797d
cache graphType
a1d9686
Merge branch 'main' into upgrade-graphQL
hishamco 815bb84
Merge branch 'main' into upgrade-graphQL
sebastienros da7ab9e
Fix build
sebastienros 2a3b81f
Merge branch 'main' into upgrade-graphQL
sebastienros 193bda0
Merge branch 'main' into upgrade-graphQL
MikeAlhayek File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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
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
10 changes: 10 additions & 0 deletions
10
src/OrchardCore.Modules/OrchardCore.Apis.GraphQL/GraphQLNamedQueryRequest.cs
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 |
---|---|---|
@@ -0,0 +1,10 @@ | ||
|
||
using GraphQL.Transport; | ||
|
||
namespace OrchardCore.Apis.GraphQL | ||
{ | ||
public class GraphQLNamedQueryRequest : GraphQLRequest | ||
{ | ||
public string NamedQuery { get; set; } | ||
} | ||
} |
13 changes: 0 additions & 13 deletions
13
src/OrchardCore.Modules/OrchardCore.Apis.GraphQL/GraphQLRequest.cs
This file was deleted.
Oops, something went wrong.
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,4 +1,5 @@ | ||
using System; | ||
using System.Text.Json; | ||
using GraphQL; | ||
using GraphQL.DataLoader; | ||
using GraphQL.Execution; | ||
|
@@ -36,7 +37,6 @@ public Startup(IOptions<AdminOptions> adminOptions, IHostEnvironment hostingEnvi | |
public override void ConfigureServices(IServiceCollection services) | ||
{ | ||
services.AddSingleton<IDocumentExecuter, DocumentExecuter>(); | ||
services.AddSingleton<IDocumentWriter, DocumentWriter>(); | ||
services.AddSingleton<IDataLoaderContextAccessor, DataLoaderContextAccessor>(); | ||
services.AddSingleton<IDocumentExecutionListener, DataLoaderDocumentListener>(); | ||
|
||
|
@@ -47,11 +47,13 @@ public override void ConfigureServices(IServiceCollection services) | |
services.AddSingleton<IErrorInfoProvider>(services => | ||
{ | ||
var settings = services.GetRequiredService<IOptions<GraphQLSettings>>(); | ||
return new ErrorInfoProvider(new ErrorInfoProviderOptions { ExposeExceptionStackTrace = settings.Value.ExposeExceptions }); | ||
return new ErrorInfoProvider(new ErrorInfoProviderOptions { ExposeExceptionDetails = settings.Value.ExposeExceptions }); | ||
}); | ||
|
||
services.AddScoped<IPermissionProvider, Permissions>(); | ||
services.AddTransient<INavigationProvider, AdminMenu>(); | ||
services.AddSingleton<GraphQLMiddleware>(); | ||
services.AddGraphQL(builder => builder.AddSystemTextJson()); | ||
|
||
services.AddOptions<GraphQLSettings>().Configure<IShellConfiguration>((c, configuration) => | ||
{ | ||
|
@@ -72,7 +74,7 @@ public override void ConfigureServices(IServiceCollection services) | |
User = ctx.User, | ||
}; | ||
c.ExposeExceptions = exposeExceptions; | ||
c.MaxDepth = configuration.GetValue<int?>($"OrchardCore_Apis_GraphQL:{nameof(GraphQLSettings.MaxDepth)}") ?? 20; | ||
c.MaxDepth = configuration.GetValue<int?>($"OrchardCore_Apis_GraphQL:{nameof(GraphQLSettings.MaxDepth)}") ?? 100; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. fix |
||
c.MaxComplexity = configuration.GetValue<int?>($"OrchardCore_Apis_GraphQL:{nameof(GraphQLSettings.MaxComplexity)}"); | ||
c.FieldImpact = configuration.GetValue<double?>($"OrchardCore_Apis_GraphQL:{nameof(GraphQLSettings.FieldImpact)}"); | ||
c.MaxNumberOfResults = configuration.GetValue<int?>($"OrchardCore_Apis_GraphQL:{nameof(GraphQLSettings.MaxNumberOfResults)}") ?? 1000; | ||
|
@@ -90,7 +92,7 @@ public override void Configure(IApplicationBuilder app, IEndpointRouteBuilder ro | |
defaults: new { controller = typeof(AdminController).ControllerName(), action = nameof(AdminController.Index) } | ||
); | ||
|
||
app.UseMiddleware<GraphQLMiddleware>(serviceProvider.GetService<IOptions<GraphQLSettings>>().Value); | ||
app.UseMiddleware<GraphQLMiddleware>(); | ||
} | ||
} | ||
} |
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.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
Class name conflict, Maybe someone has a better name