question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Metadata support for schema type definitions

See original GitHub issue

As far as I see there is currently no support to add metadata to a schema definition. Having a means to specify metadata on the various objects in graphql.schema package would allow additional server-side processing logic to be based on it.

I would like to propose adding Builder.metadata(String, Object) and Builder.metadata(Map<String, Object> metadata) methods to the various builder classes (and constructors), and having it available in data fetchers and type resolvers.

(Maybe instead of a Map<String, Object> the metadata could also be defined as a custom GraphQL introspection type __METADATA)

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:16 (15 by maintainers)

github_iconTop GitHub Comments

1reaction
andimarekcommented, May 14, 2019

I am closing this issue: We will not add completely arbitrary metadata to GraphQLSchema or Ast Nodes because it would break immutability.

But we recently added Map<String, String> to Field and will probably add it to every Node. See https://github.com/graphql-java/graphql-java/pull/1529

Because that this PR is so old: if you have new input please open a new Issue. Thanks

0reactions
bbakermancommented, Sep 18, 2017

Added a PR for this in #716

Read more comments on GitHub >

github_iconTop Results From Across the Web

Metadata for Data Management: A Tutorial: Standards/Schema
This metadata schema is for ecological data. EML is implemented as a series of XML document types that can by used in a...
Read more >
Metadata Schema - an overview | ScienceDirect Topics
Data dictionary : A formal document describing the metadata schema for a particular collection, defining each field, how data in each field is...
Read more >
Metadata schemas | Adobe Experience Manager
Metadata schema defines the layout of the properties page and the metadata properties displayed for assets. Learn how to create custom ...
Read more >
Configuration schema/metadata - Drupal
Properties; Types supported in metadata files; Sequence definitions; Dynamic type references; Naming your schema files; Code style to use ...
Read more >
Define Metadata Schema - Oracle Help Center
Metadata schema is a set of user-defined attributes that extend the system-defined normalized data. The normalized data is generated from the source document...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found