|
|
No server side validation with GWT/GAE ?
Hi,
I wonder if this is a bug or if I did something wrong but the server side validation doesn't seem to be implemented on GAE.
I get the validation errors on the client side and I'm able to display them but the data gets persisted nonetheless in the datastore.
My workaround:Code:
@Configurable
@Entity
@RooJavaBean
@RooToString
@RooEntity
@UniqueEmail
public class User {
private Validator validator = Validation.buildDefaultValidatorFactory()
.getValidator();
@PrePersist
@PreUpdate
public void prePersist() throws NoSuchAlgorithmException {
if(!validator.validate(this).isEmpty())
throw new ValidationException();
}
So, not implemented yet, bug or error from me ? |
|