[ 
https://issues.jboss.org/browse/SEAMVALIDATE-5?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12585049#comment-12585049
 ] 

Gunnar Morling commented on SEAMVALIDATE-5:
-------------------------------------------

Seam Validation is based on Hibernate Validator 4.2. GlassFish 3.1 ships with 
Hibernate Validator 4.1 which does not yet contain the method validation 
feature.

A while ago I contacted Ed Burns from Oracle (who's in charge there for 
integrating HV into GlassFish) in order to find out how the HV version in GF 
could be updated. His answer was that this currently is not easily possible as 
HV is contained in GlassFish's core installation package, and therefore can't 
be updated separately atm. There is an issue 
(http://java.net/jira/browse/GLASSFISH-15648) in GF's JIRA addressing this 
situation.

I tried to work around this problem, but I didn't find a really satisfying 
solution so far:

* Deploying HV 4.2 within an application (EAR/WAR) doesn't work as the HV 
version contained in GF takes precedence
* Removing the HV version contained in GF (an OSGi module named 
bean-validator.jar) doesn't work, as GF itself uses Bean Validation internally 
and therefore doesn't start without that module
* Creating a custom OSGi module for HV 4.2 and deploying it into GF instead of 
bean-validator.jar basically works but altering/replacing GF's basic OSGi 
modules is probably not what most people would want

So currently I don't see a good solution than waiting for another GF version 
which comprises HV 4.2.


> Helloworld example does not work properly in Glassfish
> ------------------------------------------------------
>
>                 Key: SEAMVALIDATE-5
>                 URL: https://issues.jboss.org/browse/SEAMVALIDATE-5
>             Project: Seam Validation
>          Issue Type: Bug
>    Affects Versions: 3.0.0.CR1
>         Environment: Glassfish v 3.1 
> (http://dlc.sun.com.edgesuite.net/glassfish/3.1/release/glassfish-3.1.zip)
>            Reporter: Martin Gencur
>            Assignee: Gunnar Morling
>
> I used the "jee" profile to build the application. Deploying and the initial 
> page are just OK but after entering a name and clicking on the OK button the 
> following exception is thrown:
> [#|2011-02-28T14:40:46.762+0100|WARNING|glassfish3.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=85;_ThreadName=Thread-1;|StandardWrapperValve[Seam
>  Validation Example Servlet]: PWC1406: Servlet.service() for servlet Seam 
> Validation Example Servlet threw exception
> javax.validation.ValidationException: Type interface 
> org.hibernate.validator.MethodValidator not supported
>       at 
> org.hibernate.validator.engine.ValidatorImpl.unwrap(ValidatorImpl.java:157)
>       at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>       at 
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>       at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>       at java.lang.reflect.Method.invoke(Method.java:597)
>       at 
> org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:305)
>       at 
> org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:54)
>       at 
> org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:163)
>       at 
> org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:299)
>       at 
> org.jboss.weld.bean.builtin.CallableMethodHandler.invoke(CallableMethodHandler.java:57)
>       at 
> org.jboss.weld.bean.proxy.EnterpriseTargetBeanInstance.invoke(EnterpriseTargetBeanInstance.java:62)
>       at 
> org.jboss.weld.bean.proxy.ProxyMethodHandler.invoke(ProxyMethodHandler.java:125)
>       at 
> org.jboss.weldx.validation.org$jboss$weld$bean-WEB-INF$lib$seam-validation-impl-3$0$0$CR1-Built-in-Validator_$$_WeldProxy.unwrap(org$jboss$weld$bean-WEB-INF$lib$seam-validation-impl-3$0$0$CR1-Built-in-Validator_$$_WeldProxy.java)
>       at 
> org.jboss.seam.validation.ValidationInterceptor.validateMethodInvocation(ValidationInterceptor.java:48)
>       at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>       at 
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>       at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>       at java.lang.reflect.Method.invoke(Method.java:597)
>       at 
> org.jboss.interceptor.proxy.InterceptorInvocation$InterceptorMethodInvocation.invoke(InterceptorInvocation.java:72)
>       at 
> org.jboss.interceptor.proxy.SimpleInterceptionChain.invokeNextInterceptor(SimpleInterceptionChain.java:82)
>       at 
> org.jboss.interceptor.proxy.InterceptorMethodHandler.executeInterception(InterceptorMethodHandler.java:133)
>       at 
> org.jboss.interceptor.proxy.InterceptorMethodHandler.invoke(InterceptorMethodHandler.java:112)
>       at 
> org.jboss.weld.bean.proxy.CombinedInterceptorAndDecoratorStackMethodHandler.invoke(CombinedInterceptorAndDecoratorStackMethodHandler.java:65)
>       at 
> org.jboss.seam.validation.org$jboss$weld$bean-validation-helloworld-ManagedBean-class_org$jboss$seam$validation$HelloWorldService_$$_WeldSubclass.sayHello(org$jboss$weld$bean-validation-helloworld-ManagedBean-class_org$jboss$seam$validation$HelloWorldService_$$_WeldSubclass.java)
>       at 
> org.jboss.seam.validation.org$jboss$weld$bean-validation-helloworld-ManagedBean-class_org$jboss$seam$validation$HelloWorldService_$$_WeldClientProxy.sayHello(org$jboss$weld$bean-validation-helloworld-ManagedBean-class_org$jboss$seam$validation$HelloWorldService_$$_WeldClientProxy.java)
>       at 
> org.jboss.seam.validation.HelloWorldServlet.doGet(HelloWorldServlet.java:47)
>       at javax.servlet.http.HttpServlet.service(HttpServlet.java:735)
>       at javax.servlet.http.HttpServlet.service(HttpServlet.java:848)
>       at 
> org.apache.catalina.core.StandardWrapper.service(StandardWrapper.java:1534)
>       at 
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:281)
>       at 
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
>       at 
> org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:655)
>       at 
> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:595)
>       at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:98)
>       at 
> com.sun.enterprise.web.PESessionLockingStandardPipeline.invoke(PESessionLockingStandardPipeline.java:91)
>       at 
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:162)
>       at 
> org.apache.catalina.connector.CoyoteAdapter.doService(CoyoteAdapter.java:326)
>       at 
> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:227)
>       at 
> com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:170)
>       at 
> com.sun.grizzly.http.ProcessorTask.invokeAdapter(ProcessorTask.java:822)
>       at com.sun.grizzly.http.ProcessorTask.doProcess(ProcessorTask.java:719)
>       at com.sun.grizzly.http.ProcessorTask.process(ProcessorTask.java:1013)
>       at 
> com.sun.grizzly.http.DefaultProtocolFilter.execute(DefaultProtocolFilter.java:225)
>       at 
> com.sun.grizzly.DefaultProtocolChain.executeProtocolFilter(DefaultProtocolChain.java:137)
>       at 
> com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:104)
>       at 
> com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:90)
>       at 
> com.sun.grizzly.http.HttpProtocolChain.execute(HttpProtocolChain.java:79)
>       at 
> com.sun.grizzly.ProtocolChainContextTask.doCall(ProtocolChainContextTask.java:54)
>       at 
> com.sun.grizzly.SelectionKeyContextTask.call(SelectionKeyContextTask.java:59)
>       at com.sun.grizzly.ContextTask.run(ContextTask.java:71)
>       at 
> com.sun.grizzly.util.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:532)
>       at 
> com.sun.grizzly.util.AbstractThreadPool$Worker.run(AbstractThreadPool.java:513)
>       at java.lang.Thread.run(Thread.java:619)

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
_______________________________________________
seam-issues mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/seam-issues

Reply via email to