Closed
Description
When initialising the same schema for multiple ServiceCollection's you can only do this when calling UseGraphQL before you run AddGraphQL on the second collection.
var service1Collection = new ServiceCollection();
var service2Collection = new ServiceCollection();
service1Collection.AddGraphQL<CandleSchema>(options =>
{
options.AddGraphType<Candle>();
});
service2Collection.AddGraphQL<CandleSchema>(options =>
{
options.AddGraphType<Candle>();
});
This produces the error: The schema type CandleSchema has already been registered. Each schema type may only be registered once with GraphQL.
Metadata
Metadata
Assignees
Labels
Something isn't workingSomething isn't working