You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@bval.apache.org by "Matt Benson (Commented) (JIRA)" <ji...@apache.org> on 2011/12/02 23:13:40 UTC

[jira] [Commented] (BVAL-63) use java.util.ServiceLoader in DefaultValidationProviderResolver#getValidationProviders()

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

Matt Benson commented on BVAL-63:
---------------------------------

I propose to resolve this as LATER, assuming that the next version of the spec will release us from supporting 1.5.
                
> use java.util.ServiceLoader in DefaultValidationProviderResolver#getValidationProviders()
> -----------------------------------------------------------------------------------------
>
>                 Key: BVAL-63
>                 URL: https://issues.apache.org/jira/browse/BVAL-63
>             Project: BeanValidation
>          Issue Type: Bug
>          Components: jsr303
>    Affects Versions: 0.1-incubating
>            Reporter: Mark Struberg
>            Assignee: Donald Woods
>             Fix For: 0.4-incubating
>
>         Attachments: bval-jsr303-63.patch
>
>
> 4.4.4.1
> > By default, providers are resolved using the Service Provider pattern described in
> > http://java.sun.com/j2se/1.5.0/docs/guide/jar/jar.html#Service%20Provider. Bean Validation providers must supply a
> > service provider configuration file by creating a text file javax.validation.spi.ValidationProvider and placing
> > it in the META-INF/services directory of one of its jar files. The content of the file should contain the name of the
> > provider implementation class of the javax.validation.spi.ValidationProvider interface.
> But we internally currently dont use the java.util.ServiceLoader but do a
> cl.getResources(SPI_CFG);
> instead in DefaultValidationProviderResolver#getValidationProviders()
> This is imo a bug in our impl!
> See here for how to use the ServiceLoader mechanism properly:
> https://svn.apache.org/repos/asf/openwebbeans/trunk/webbeans-impl/src/main/java/org/apache/webbeans/plugins/PluginLoader.java 

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira