dgs-framework icon indicating copy to clipboard operation
dgs-framework copied to clipboard

bug: CORS error when using SSE with webflux

Open esfomeado opened this issue 3 years ago • 3 comments

I created a sample project making the use of webflux and disabled CORS and it works for the /graphql endpoint but no for the /subscriptions one.

Expected behavior

It should disabled CORS for all endpoints.

Actual behavior

It does not disabled for subscriptions.

Steps to reproduce

Clone: https://github.com/esfomeado/dgs-cors

Do a request with SSE or fetch:

subscription {
  liveCoinsPrice {
    name,
    price,
    time
  }
}

esfomeado avatar Jul 07 '22 18:07 esfomeado

Thanks for reporting!

srinivasankavitha avatar Jul 21 '22 19:07 srinivasankavitha

I don't have this issue with my example: https://github.com/Ancient-Dragon/dgs-sse-subscriptions-backend-example

Ancient-Dragon avatar Jul 22 '22 08:07 Ancient-Dragon

Could you add more info about this incident please? I didn't find a way to reproduce it using this repo. Thanks in advance.

ClaudenirFreitas avatar Jul 24 '22 13:07 ClaudenirFreitas