[JBoss JIRA] (JBTM-3186) Safeguard LRA filters for situations when CDI is not available
by Thomas Jenkinson (Jira)
[ https://issues.jboss.org/browse/JBTM-3186?page=com.atlassian.jira.plugin.... ]
Thomas Jenkinson updated JBTM-3186:
-----------------------------------
Fix Version/s: 5.10.0.Final
> Safeguard LRA filters for situations when CDI is not available
> ---------------------------------------------------------------
>
> Key: JBTM-3186
> URL: https://issues.jboss.org/browse/JBTM-3186
> Project: JBoss Transaction Manager
> Issue Type: Bug
> Components: LRA
> Reporter: Martin Stefanko
> Assignee: Martin Stefanko
> Priority: Major
> Fix For: 5.10.0.Final
>
>
> When CDI is not available in LRA microservice, following exception is thrown:
> {code:java}
> Caused by: java.lang.NullPointerException
> at io.narayana.lra.filter.ServerLRAFilter.filter(ServerLRAFilter.java:311)
> {code}
> This is thrown because CDI is not available in the container. The check for null injection can prohibit this behavior and LRA can still function for REST-based services in case CDI is not present.
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
5 years
[JBoss JIRA] (JBTM-3187) Add MessageBodyWriter for ParticipantStatus and application/octet-stream media type
by Thomas Jenkinson (Jira)
[ https://issues.jboss.org/browse/JBTM-3187?page=com.atlassian.jira.plugin.... ]
Thomas Jenkinson closed JBTM-3187.
----------------------------------
> Add MessageBodyWriter for ParticipantStatus and application/octet-stream media type
> -----------------------------------------------------------------------------------
>
> Key: JBTM-3187
> URL: https://issues.jboss.org/browse/JBTM-3187
> Project: JBoss Transaction Manager
> Issue Type: Enhancement
> Components: LRA
> Affects Versions: 5.9.8.Final
> Reporter: Martin Stefanko
> Assignee: Martin Stefanko
> Priority: Major
> Fix For: 5.10.0.Final
>
>
> application/octet-stream is the default media type in RESTEasy which is used when {{@Produces}} value is not specified. We are always expecting {{String}} values from LRA participant methods so instead of requiring {{(a)Produces(MediaType.TEXT_PLAIN)}} on each {{@Compensate}}, {{@Complete}}, {{@Status}}, etc. methods we can include {{MessageBodyWriter<ParticipantStatus>}} implementation in {{narayana-lra}} module which will just transform {{ParticipantStatus}} value to {{String}}.
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
5 years
[JBoss JIRA] (JBTM-3187) Add MessageBodyWriter for ParticipantStatus and application/octet-stream media type
by Thomas Jenkinson (Jira)
[ https://issues.jboss.org/browse/JBTM-3187?page=com.atlassian.jira.plugin.... ]
Thomas Jenkinson updated JBTM-3187:
-----------------------------------
Fix Version/s: 5.10.0.Final
> Add MessageBodyWriter for ParticipantStatus and application/octet-stream media type
> -----------------------------------------------------------------------------------
>
> Key: JBTM-3187
> URL: https://issues.jboss.org/browse/JBTM-3187
> Project: JBoss Transaction Manager
> Issue Type: Enhancement
> Components: LRA
> Affects Versions: 5.9.8.Final
> Reporter: Martin Stefanko
> Assignee: Martin Stefanko
> Priority: Major
> Fix For: 5.10.0.Final
>
>
> application/octet-stream is the default media type in RESTEasy which is used when {{@Produces}} value is not specified. We are always expecting {{String}} values from LRA participant methods so instead of requiring {{(a)Produces(MediaType.TEXT_PLAIN)}} on each {{@Compensate}}, {{@Complete}}, {{@Status}}, etc. methods we can include {{MessageBodyWriter<ParticipantStatus>}} implementation in {{narayana-lra}} module which will just transform {{ParticipantStatus}} value to {{String}}.
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
5 years
[JBoss JIRA] (JBTM-3180) LRARecord http compliance: Entity null for PUT
by Thomas Jenkinson (Jira)
[ https://issues.jboss.org/browse/JBTM-3180?page=com.atlassian.jira.plugin.... ]
Thomas Jenkinson closed JBTM-3180.
----------------------------------
> LRARecord http compliance: Entity null for PUT
> ----------------------------------------------
>
> Key: JBTM-3180
> URL: https://issues.jboss.org/browse/JBTM-3180
> Project: JBoss Transaction Manager
> Issue Type: Bug
> Components: LRA
> Affects Versions: 5.9.7.Final
> Reporter: Paul Parkinson
> Assignee: Michael Musgrove
> Priority: Minor
> Fix For: 5.10.0.Final
>
>
> LRARecord has...
> case "javax.ws.rs.PUT":
> return asyncInvoker.put(Entity.text(null));
> whereas entity should never be null for PUT
> I see this comment has been there since the code was first added and so perhaps this is the desired...
> // return asyncInvoker.put(Entity.entity(compensatorData, mediaType));
> If not perhaps simply Entity.text("") should suffice (and has in my tests).
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
5 years
[JBoss JIRA] (JBTM-3180) LRARecord http compliance: Entity null for PUT
by Thomas Jenkinson (Jira)
[ https://issues.jboss.org/browse/JBTM-3180?page=com.atlassian.jira.plugin.... ]
Thomas Jenkinson updated JBTM-3180:
-----------------------------------
Fix Version/s: 5.10.0.Final
> LRARecord http compliance: Entity null for PUT
> ----------------------------------------------
>
> Key: JBTM-3180
> URL: https://issues.jboss.org/browse/JBTM-3180
> Project: JBoss Transaction Manager
> Issue Type: Bug
> Components: LRA
> Affects Versions: 5.9.7.Final
> Reporter: Paul Parkinson
> Assignee: Michael Musgrove
> Priority: Minor
> Fix For: 5.10.0.Final
>
>
> LRARecord has...
> case "javax.ws.rs.PUT":
> return asyncInvoker.put(Entity.text(null));
> whereas entity should never be null for PUT
> I see this comment has been there since the code was first added and so perhaps this is the desired...
> // return asyncInvoker.put(Entity.entity(compensatorData, mediaType));
> If not perhaps simply Entity.text("") should suffice (and has in my tests).
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
5 years