Uploaded image for project: 'CXF'
  1. CXF
  2. CXF-6706

Bean validation seems to not be working in OSGi

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 3.1.4, 3.2.0
    • 3.1.5, 3.2.0
    • None
    • None
    • Unknown

    Description

      Using Karaf 4.0.2,

      if you take this repo:

      git@github.com:benson-basis/cxf-karaf-validation-tc.git

      and checkout the use-cxf-support branch, it will build you a Karaf assembly that, when you poke the service (http://localhost:8181/cxf/validate)

      will yield the following backtrace. This assumes that you are up to date with my fix to cxf-6705 which is on master and the 3.1.x branch.

      javax.validation.ValidationException: Unable to find a default provider
      	at javax.validation.Validation$GenericBootstrapImpl.configure(Validation.java:264)
      	at javax.validation.Validation.buildDefaultValidatorFactory(Validation.java:111)
      	at org.apache.cxf.validation.BeanValidationProvider.<init>(BeanValidationProvider.java:45)
      	at com.basistech.ts.impl.TrivialService.validate(TrivialService.java:50)
      

      Attachments

        Issue Links

          Activity

            People

              bmargulies Benson Margulies
              bmargulies Benson Margulies
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: