Re: 2.3.0m1 errors import javax.validation.ConstraintViolation

529 views
Skip to first unread message

Juan Pablo Gardella

unread,
Apr 18, 2011, 2:46:43 PM4/18/11
to google-we...@googlegroups.com
You need add javax.validation.api classes in your classpath. Now, gwt has this dependency

2011/4/17 Sunyc <suny...@gmail.com>
[ERROR] [xxx] - Line 20: The import
javax.validation.ConstraintViolation cannot be resolved

This seems to be a j2ee class.

--
You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group.
To post to this group, send email to google-we...@googlegroups.com.
To unsubscribe from this group, send email to google-web-tool...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.


David Chandler

unread,
Apr 18, 2011, 2:52:40 PM4/18/11
to google-we...@googlegroups.com
You need to add gwt-servlet-deps.jar to WEB-INF/lib. You can find it in build/lib.

GWT 2.2 required validation-api if you're using RequestFactory, but in 2.3, gwt-user has a dependency on it also. For maven projects, we'll update the 2.3 POM with the transitive dependency, but for non-maven projects, it's unfortunately not safe to bundle validation-api like we do with many other jars because some J2EE containers will break if you include validation-api without a corresponding impl.

Google Plugin for Eclipse will add the new dependency to the classpath automatically. If you're not using GPE or maven, you'll have to add it manually for now.

HTH,
/dmc


On Sun, Apr 17, 2011 at 8:20 PM, Sunyc <suny...@gmail.com> wrote:
[ERROR] [xxx] - Line 20: The import
javax.validation.ConstraintViolation cannot be resolved

This seems to be a j2ee class.

--
You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group.
To post to this group, send email to google-we...@googlegroups.com.
To unsubscribe from this group, send email to google-web-tool...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.




--
David Chandler
Developer Programs Engineer, Google Web Toolkit
w: http://code.google.com/
b: http://googlewebtoolkit.blogspot.com/
t: @googledevtools

Sunyc

unread,
Apr 17, 2011, 8:20:16 PM4/17/11
to Google Web Toolkit
Reply all
Reply to author
Forward
0 new messages