Uploaded image for project: 'BVal'
  1. BVal
  2. BVAL-13

ConstraintViolationImpl must be Serialziable according to JSR303 spec

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 0.1-incubating
    • Fix Version/s: 0.1-incubating
    • Component/s: None
    • Labels:
      None

      Description

      JSR 303 Spec., chapter 4.2. ConstraintViolation: "Bean Validation implementations should ensure that a ConstraintViolation implementation is Serializable provided that the root bean, the leaf bean, the invalid value and keys in the Path object are Serializable objects. If a user wishes to send ConstraintViolation remotely, it should make sure the object graph validated is itself Serializable."

      Problem ist: ConstraintViolationImpl currently is not serializable, because ConstraintValidation is not either (and AccessStrategy, Field, Method, all ConstraintValidators are also NOT serializable...)

      I think the solution could be to implement methods for serialization/deserialization or, even better, remove field type ConstraintValidation from class ConstraintViolationImpl, so that ConstraintViolationImpl can become serializable.

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              romanstumm Roman Stumm
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: