Uploaded image for project: 'Camel'
  1. Camel
  2. CAMEL-1537 Predicate for validation
  3. CAMEL-1276

Add validation feature to Camel framework in order to validate data linked/binded to POJO

    XMLWordPrintableJSON

Details

    • New Feature
    • Status: Closed
    • Major
    • Resolution: Duplicate
    • None
    • 2.3.0
    • None
    • None

    Description

      With bindy, jaxb and probably other binding frameworks, it would be interesting to have a validate option in camel that we can use in combination with by example unmarshall

      from(uri)
      .unmarshall(bindy or jaxb or ArtixDS or ...)
      .validate(nonblocking)
      .to())

      The purpose of this feature will be to :

      • verify mandatory fields/properties of POJO,
      • apply business rules on the data received,
      • ...

      Ex, in an csv record, the order n° field is mandatory and the order type must be equal to N for new order, C for cancel or U for update.

      Remarks :

      • One parameter that we can provide to the validation method could be "block or non block" to generate an array list of errors without creating an error in the application. This option is interesting because it allows to keep the POJO and save though Hibernate/Ibatis the data in the database and to send a report to the issuer to inform it about the errors found in the CSV, fixedlength, ... files received
      • Spring 3 who will provide validation support through annotation could be a good candidate.

      Attachments

        Activity

          People

            muellerc Christian Müller
            cmoulliard Moulliard Charles
            Votes:
            1 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: