commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Niall Pemberton" <>
Subject Re: error in Common Validor 1.2.0 with Struts 1.2.8
Date Fri, 03 Mar 2006 16:49:19 GMT
First I tried to re-create this problem in the Struts 1.2 branch, by adding
validation for the three validators which use ORO (email, url and mask) to
the type form:

...and dropping in the Validator 1.2.0 jar - but it worked fine for me (with
ORO 2.0.7)

The difference between Validator 1.1.4 and Validator 1.2.0 in respect to
EmailValidator use of ORO is that the 1.2.0 version calls the Perl5Util's
substitute() method:

... which in turn calls the org.apache.oro.text.regex.Util's substitute
method which you're getting the "method not found" issue on. According to
the ORO javadoc - that flavour of the substitute() method was added in ORO
2.0.6 (although it looks to me like it was actually added on 2.0.5)

So it looks to me like your deployment is picking up a version of ORO
earlier than 2.0.5 / 2.0.6.


----- Original Message ----- 
From: "John D Dinh" <>
Sent: Thursday, March 02, 2006 11:31 PM


I'm getting an error when validating email with Common Validator 1.2.0 in
conjunction with Struts 1.2.8 and Jakarta ORO 2.0.7 (we also tried the
latest ORO 2.0.8).

[3/2/06 13:39:21:469 PST] 19c79c30 WebGroup      E SRVE0026E: [Servlet
Error]-[org.apache.oro.text.regex.Util: method
not found]: java.lang.NoSuchMethodError: org.apache.oro.text.regex.Util:
not found
    at org.apache.oro.text.perl.Perl5Util.substitute(Unknown Source)
    at org.apache.oro.text.perl.Perl5Util.substitute(Unknown Source)
    at org.apache.commons.validator.EmailValidator.stripComments(
    at org.apache.commons.validator.EmailValidator.isValid(
    at org.apache.commons.validator.GenericValidator.isEmail(
    at org.apache.struts.validator.FieldChecks.validateEmail(

Rolled back to Common Validator 1.1.4 works, but we like to take advantages
of numerous fixes in email validation in the latest Common Validator.
Any help would be greatly appreciated.

john dinh

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message