Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use of enum LRAStatus as entity parameter #347

Closed
spericas opened this issue Apr 1, 2021 · 6 comments · Fixed by #354
Closed

Use of enum LRAStatus as entity parameter #347

spericas opened this issue Apr 1, 2021 · 6 comments · Fixed by #354
Milestone

Comments

@spericas
Copy link

spericas commented Apr 1, 2021

The LRAStatus enum is used as a JAX-RS entity parameter in the spec and the TCKs. Although some JAX-RS implementations support this usage, it is not mandated by the JAX-RS specification. More precisely, implementations are not required to provide an out-of-the-box message body reader to handle enums in this manner (they are required to handle enums this way associated with *Param injections).

I suppose it is possible to mandate LRA implementations to extend a JAX-RS implementation to support this, but this does not seem to be mentioned anywhere so I suspect the assumption made here is that all JAX-RS implementations support this, which is not the case.

A short clarification on what is expected would be useful.

@mmusgrov mmusgrov added this to the 2.0 milestone Sep 3, 2021
@mmusgrov
Copy link
Contributor

mmusgrov commented Sep 7, 2021

An alternative would be to go back to using a string for returning the LRAStatus, the downside of doing this is that it will require users to modify their applications.

@xstefank
Copy link
Member

xstefank commented Sep 7, 2021

@mmusgrov I expect this will need to have the spec text changes (more than just typos) and/or bigger TCK changes which means we can't include it in 2.0.

@mmusgrov
Copy link
Contributor

mmusgrov commented Sep 7, 2021

Agreed, let's just go with Santiago's recommendation (of adding a brief note about it to the spec).
I'd suggest adding the note to the javadoc for LRAStatus.

Actually, if this is a requirement on implementations then the note would be better placed in the spec document itself.

@Emily-Jiang
Copy link
Member

In Jakarta 9.1 alignment (LRA 2.0), only javax to jakarta namespace updates are allowed with the exception of tck bug fixes, some typos. No other functional updates are allowed. If this proposed change does not impact any tck or impl updates, it can be included. Otherwise, it is better to wait after the 2.0.

@mmusgrov
Copy link
Contributor

mmusgrov commented Sep 7, 2021

It's a spec clarification (but if people prefer moving it to milestone 2.x then that's fine with me too).

@Emily-Jiang
Copy link
Member

It's a spec clarification (but if people prefer moving it to milestone 2.x then that's fine with me too).
In this case, it can go into 2.0. If the team wants to move to 2.x, it is also okay.

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 a pull request may close this issue.

4 participants