Uploaded image for project: 'Quarkus'
  1. Quarkus
  2. QUARKUS-2745

OutboundSseEvent is not correctly serialized

    XMLWordPrintable

Details

    Description

      Closes #10673

      This request allows special server sent events in the form of

      ```java
      @GET
      @Produces(MediaType.SERVER_SENT_EVENTS)
      public Multi<OutboundSseEvent> consume(@Context Sse sse)

      { return Multi.createFrom() .item(sse.newEventBuilder().id(UUID.randomUUID().toString()) .mediaType(MediaType.TEXT_HTML_TYPE).name("whatever").data("<h3>EVENT DATA</h3>") .reconnectDelay(3000).build()); }

      ```
      I'd like to write a test for that, but there is no existing one for the changed class. That's probably due to the static access of SseUtil.send() which is impossible to mock (as far as I know).

      Attachments

        Activity

          People

            Unassigned Unassigned
            probinso_jira Quarkus JIRA Bot
            Pablo Gonzalez Granados Pablo Gonzalez Granados (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: