Skip to content

Cannot use java.util.Date #1198

Answered by dariuszkuc
und3rs asked this question in Q&A
Jun 24, 2021 · 1 comments · 5 replies
Discussion options

You must be logged in to vote

One of the reasons we explicitly require graphql.packages property is to limit the scope of which packages can be scanned and we don't accidentally expose something we are not supposed to (like java.util.*).

See https://expediagroup.github.io/graphql-kotlin/docs/schema-generator/writing-schemas/scalars#custom-scalars. You will need to provide custom hook + logic to coerce the values (i.e. how to serialize/deserialize Date representation).

Replies: 1 comment 5 replies

Comment options

You must be logged in to vote
5 replies
@smyrick
Comment options

@und3rs
Comment options

@und3rs
Comment options

@smyrick
Comment options

@und3rs
Comment options

Answer selected by smyrick
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants
Converted from issue

This discussion was converted from issue #1197 on June 24, 2021 14:01.