[
https://issues.apache.org/jira/browse/WINK-193?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12758700#action_12758700
]
Michael Elman commented on WINK-193:
------------------------------------
Well, I made the change.
I used parts from the suggested patch, especially the unit tests.
Some concerns regarding the implementation and changes that I did:
* The changes apply for context resolvers, message body writers and readers.
* The sorting order is:
*# By media type
*# By generic type
*# By priority
Regarding system providers: they are added with priority 0.1, while the default
priority is 0.5, so the last key will ensure that user providers are invoked
before the system providers if keys one and two are equal.
I've commented one of the unit tests in
ProvidersMessageBodyTest.testMessageBodyWriters since it assumes that
String2Provider should override StringProvider. This is incorrect, since in the
test there is no difference between user and system providers.
In addition, I've added feature that the later provider is registered, the
higher priority it will get. I use 0.00000000001 as a "counter" that is added.
The assumption that none will use so small numbers to set the priority, while
some may try to use providers order as a priority.
> JAX-RS 1.1 support: C004
> -------------------------
>
> Key: WINK-193
> URL: https://issues.apache.org/jira/browse/WINK-193
> Project: Wink
> Issue Type: Improvement
> Reporter: Mike Rheinheimer
> Attachments: WINK-193.patch, WINK-193.patch
>
>
> Need support for C004 at
> http://jcp.org/aboutJava/communityprocess/maintenance/jsr311/311ChangeLog.html
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.