You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cxf.apache.org by "Timothy James Ward (Jira)" <ji...@apache.org> on 2021/06/08 16:22:00 UTC

[jira] [Commented] (CXF-8545) Unable to connect to POST methods with SseEventSource

    [ https://issues.apache.org/jira/browse/CXF-8545?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17359445#comment-17359445 ] 

Timothy James Ward commented on CXF-8545:
-----------------------------------------

An example of how this could be added in a non-invasive way is provided in [this Pull Request|https://github.com/apache/cxf/pull/813]

> Unable to connect to POST methods with SseEventSource
> -----------------------------------------------------
>
>                 Key: CXF-8545
>                 URL: https://issues.apache.org/jira/browse/CXF-8545
>             Project: CXF
>          Issue Type: New Feature
>          Components: JAX-RS
>    Affects Versions: 3.2.14
>            Reporter: Timothy James Ward
>            Priority: Major
>
> The SseEventSource is primarily targeted at using HTTP GET requests to initiate the connection. It is extremely difficult to use a POST request instead.
> POST requests are useful for when information (e.g. server side event filtering) needs to be passed in the request, but that information is too big for query parameters or it contains URL unsafe characters, or it is serialised using a Content-Type that can be decoded by JAX-RS body converters.
>  
> It should be simple enough to add a configuration property into the web target passed to the SseEventSource. This could map to a JAX-RS entity. If the entity is present then it is used as the body of the post. Otherwise a GET is used.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)