Skip to content
This repository was archived by the owner on Dec 19, 2023. It is now read-only.
This repository was archived by the owner on Dec 19, 2023. It is now read-only.

Subscription  #366

Closed
Closed
@BaptisteMeynier

Description

@BaptisteMeynier

Hello,
I'm trying to use Subscription feature. I use a jquery client, I manage to call the server but I get the following error:

Caused by: com.fasterxml.jackson.databind.exc.MismatchedInputException: Cannot construct instance of `graphql.kickstart.execution.GraphQLRequest` (although at least one Creator exists): no String-argument constructor/factory method to deserialize from String value.

The request is formated like this:

{
"query":"subscription LastFamilySubscription { \n    lastFamily \\{       id        name      \\}\\}",
"variables":{}
}

I suppose that I forgot to provide a setting like an ObjectMapper.

When I use the dependency bellow, it's work well and I manage to get the stream

<dependency>
   <groupId>com.graphql-java</groupId>
   <artifactId>graphql-java-tools</artifactId>
   <version>5.2.4</version>
</dependency>

My project is host on https://github.com/BaptisteMeynier/Graphql-Subscription/blob/master/src/main/java/com/meynier/spring/graphql/graphql/FishSubscriptionResolver.java

Thx a lot

Regards

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions