Skip to content

Conversation

@tdraier
Copy link
Contributor

@tdraier tdraier commented Jul 26, 2018

Hi,

I don't know if it can be useful since you're working on subscription rework, but I needed a simple SSE implementation of subscriptions on 4.7.0 and implemented this. I think some part can still be integrated :

  • SSE support itself, handled in doQuery when ExecutionResult is a subscription result
  • Default subscription strategy was not set
  • readOnlySchema must include subscriptions ( I'm using SSE with GET requests )
  • OSGi servlet register subscriptions with new "SubscriptionsProvider"
  • OSGi servlet support async

Also needed to upgrade graphql-java because of graphql-java/graphql-java#844

Feel free to take anything from here or drop it ..

Regards

@oliemansm
Copy link
Member

I'm not familiar with SSE myself, but after quickly scanning this article https://www.html5rocks.com/en/tutorials/eventsource/basics/ I understand it's an alternative to WebSockets with some differences in approach that could be relevant depending on the use case.

The current approach is based on WebSockets so integrating this would add the alternative of using SSE instead. Sounds like a pretty good addition to me.

@apottere What do you think?

@apottere
Copy link
Contributor

apottere commented Aug 2, 2018

Yeah, it looks like a good thing to include. The PR will need to be updated to current master first, though.

@wleroux
Copy link
Contributor

wleroux commented Feb 10, 2019

@apottere I am looking into server-sent events for graphql-java and I stumbled on this issue. It appears that the current version does not support server-sent events.

Would you like me to take a stab at updating this PR to master?

@wleroux
Copy link
Contributor

wleroux commented Feb 10, 2019

I've taken a stab at porting the code here: #145.

@oliemansm
Copy link
Member

Ported by @wleroux in #145

@oliemansm oliemansm closed this Feb 16, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants