Skip to content

Disabling introspection by introspectionEnabled #499

Open
@BergJonatan

Description

@BergJonatan

Description

Disabling introspection by setting introspectionEnabled to false does not work

Expected behavior

Field types that starts with __ is blocked and not exposed.

Actual behavior

Field types such as __typename is included in the response

Steps to reproduce the bug

  1. Create GraphQLSchema bean where you return something like this:
    return SchemaParser .newParser() .file(GRAPHQL_SCHEMA) .resolvers( new RootResolver(someStorage), new SomeOtherResolver(anotherService) ) .dictionary(SomeGraphQlType.getName(), SomeGraphQlType.class) .scalars(JsonObjectScalar.JSON) .options(SchemaParserOptions.newOptions().introspectionEnabled(false).build()) .build() .makeExecutableSchema();
  2. Make a graphql query that returns a type
  3. Confirm that the __typename information exists

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions