Skip to content

Help getting started with subscriptions #114

@chelliwell

Description

@chelliwell

I'm evaluating this library for a new project. I figure the Querying is pretty solid, so I'm checking out subscriptions instead. I'm using the 'subscriptions-api' branch.
I assume GraphQL.Client.Sample is a suitable app to start with? I've modified port and subscribe message for my (Apollo) server, but hit an exception in GraphQL.Client.Http.GraphQLHttpSubscriptionResult.StartAsync() [#45]: "Cannot convert type 'Newtonsoft.Json.Linq.JObject' to 'GraphQL.Common.Response.GraphQLResponse'"
Payload is
{{ "message": "Invalid message type!" }}

I doubt my experimental server is geared up to use ws-only, but I don't think this app is configured like that anyway? I can setup and get subscription messages when I experiment using GraphQL 'Playground' UI. The server does see an onDisconnect when the client is stopped, yet doesn't see the onConnect.
I will maybe try to wireshark it, but any tips please on how to get a bit further?

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