wildfly-extras / wildfly-myfaces-feature-pack

Apache License 2.0
0 stars 3 forks source link

MyFaces exception using wildfly-myfaces-injection-1.0.0.Final.jar #7

Open mkomko opened 1 year ago

mkomko commented 1 year ago

I get a weird exception when using this feature pack on WildFly 30:

java.lang.IllegalArgumentException: row is unavailable
    at jakarta.faces.api:myfaces@4.0.1//jakarta.faces.model.ListDataModel.getRowData(ListDataModel.java:66)
    at jakarta.faces.api:myfaces@4.0.1//jakarta.faces.component.UIData.getRowData(UIData.java:498)
    at deployment.redacted.ear.redacted-web.war//org.primefaces.component.datatable.DataTable.queueEvent(DataTable.java:420)
    at deployment.redacted.ear.redacted-web.war//org.primefaces.behavior.ajax.AjaxBehaviorRenderer.decode(AjaxBehaviorRenderer.java:55)
    at jakarta.faces.api:myfaces@4.0.1//jakarta.faces.component.behavior.ClientBehaviorBase.decode(ClientBehaviorBase.java:58)
    at deployment.redacted.ear.redacted-web.war//org.primefaces.util.ComponentUtils.decodeBehaviors(ComponentUtils.java:263)
    at deployment.redacted.ear.redacted-web.war//org.primefaces.renderkit.CoreRenderer.decodeBehaviors(CoreRenderer.java:638)
    at deployment.redacted.ear.redacted-web.war//org.primefaces.component.datatable.DataTableRenderer.decode(DataTableRenderer.java:77)
    at jakarta.faces.api:myfaces@4.0.1//jakarta.faces.component.UIComponentBase.decode(UIComponentBase.java:450)
    at deployment.redacted.ear.redacted-web.war//org.primefaces.component.api.UIData.processDecodes(UIData.java:140)
    at jakarta.faces.impl:myfaces@4.0.1//org.apache.myfaces.context.servlet.PartialViewContextImpl$PhaseAwareVisitCallback.visit(PartialViewContextImpl.java:713)
    at jakarta.faces.impl:myfaces@4.0.1//org.apache.myfaces.component.visit.PartialVisitContext.invokeVisitCallback(PartialVisitContext.java:226)
    at deployment.redacted.ear.redacted-web.war//org.primefaces.component.api.UIData.visitTree(UIData.java:719)
    at jakarta.faces.api:myfaces@4.0.1//jakarta.faces.component.UIComponent.visitTree(UIComponent.java:908)
    at jakarta.faces.api:myfaces@4.0.1//jakarta.faces.component.UIComponentBase.visitTree(UIComponentBase.java:1120)
    at jakarta.faces.api:myfaces@4.0.1//jakarta.faces.component.UINamingContainer.visitTree(UINamingContainer.java:175)
    at jakarta.faces.api:myfaces@4.0.1//jakarta.faces.component.UIComponent.visitTree(UIComponent.java:908)
    at jakarta.faces.api:myfaces@4.0.1//jakarta.faces.component.UIComponentBase.visitTree(UIComponentBase.java:1120)
    at jakarta.faces.api:myfaces@4.0.1//jakarta.faces.component.UIForm.visitTree(UIForm.java:343)
    at jakarta.faces.api:myfaces@4.0.1//jakarta.faces.component.UIComponent.visitTree(UIComponent.java:908)
    at jakarta.faces.api:myfaces@4.0.1//jakarta.faces.component.UIComponentBase.visitTree(UIComponentBase.java:1120)
    at jakarta.faces.api:myfaces@4.0.1//jakarta.faces.component.UIComponent.visitTree(UIComponent.java:908)
    at jakarta.faces.api:myfaces@4.0.1//jakarta.faces.component.UIComponentBase.visitTree(UIComponentBase.java:1120)
    at jakarta.faces.impl:myfaces@4.0.1//org.apache.myfaces.context.servlet.PartialViewContextImpl.processPartialExecute(PartialViewContextImpl.java:407)
    at jakarta.faces.impl:myfaces@4.0.1//org.apache.myfaces.context.servlet.PartialViewContextImpl.processPartial(PartialViewContextImpl.java:388)
    at deployment.redacted.ear.redacted-web.war//org.primefaces.context.PrimePartialViewContext.processPartial(PrimePartialViewContext.java:65)
    at jakarta.faces.api:myfaces@4.0.1//jakarta.faces.context.PartialViewContextWrapper.processPartial(PartialViewContextWrapper.java:95)
    at deployment.redacted.ear.redacted-web.war//org.omnifaces.context.OmniPartialViewContext.processPartial(OmniPartialViewContext.java:122)
    at jakarta.faces.api:myfaces@4.0.1//jakarta.faces.component.UIViewRoot$ApplyRequestValuesPhaseProcessor.process(UIViewRoot.java:1818)
    at jakarta.faces.api:myfaces@4.0.1//jakarta.faces.component.UIViewRoot._process(UIViewRoot.java:1702)
    at jakarta.faces.api:myfaces@4.0.1//jakarta.faces.component.UIViewRoot.processDecodes(UIViewRoot.java:922)
    at jakarta.faces.impl:myfaces@4.0.1//org.apache.myfaces.lifecycle.ApplyRequestValuesExecutor.execute(ApplyRequestValuesExecutor.java:43)
    at jakarta.faces.impl:myfaces@4.0.1//org.apache.myfaces.lifecycle.LifecycleImpl.executePhase(LifecycleImpl.java:172)
    at jakarta.faces.impl:myfaces@4.0.1//org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:125)
    at jakarta.faces.api:myfaces@4.0.1//jakarta.faces.webapp.FacesServlet.service(FacesServlet.java:223)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.handlers.ServletHandler.handleRequest(ServletHandler.java:74)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:129)
    at deployment.redacted.ear.redacted-web.war//org.ocpsoft.rewrite.servlet.RewriteFilter.doFilter(RewriteFilter.java:226)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131)
    at deployment.redacted.ear.redacted-web.war//org.omnifaces.filter.CharacterEncodingFilter.doFilter(CharacterEncodingFilter.java:123)
    at deployment.redacted.ear.redacted-web.war//org.omnifaces.filter.HttpFilter.doFilter(HttpFilter.java:108)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131)
    at deployment.redacted.ear.redacted-web.war//redacted.web.auth.filter.HttpHeaderFilter.doFilter(HttpHeaderFilter.java:113)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131)
    at deployment.redacted.ear.redacted-web.war//redacted.web.auth.filter.MaintenanceFilter.doFilter(MaintenanceFilter.java:71)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131)
    at deployment.redacted.ear.redacted-web.war//redacted.web.auth.filter.ConcurrentSessionControlFilter.doFilter(ConcurrentSessionControlFilter.java:102)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131)
    at deployment.redacted.ear.redacted-web.war//redacted.web.auth.filter.TwoFactorFilter.doFilter(TwoFactorFilter.java:90)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131)
    at deployment.redacted.ear.redacted-web.war//org.apache.shiro.web.servlet.ProxiedFilterChain.doFilter(ProxiedFilterChain.java:61)
    at deployment.redacted.ear.redacted-web.war//org.apache.shiro.web.servlet.AdviceFilter.executeChain(AdviceFilter.java:108)
    at deployment.redacted.ear.redacted-web.war//org.apache.shiro.web.servlet.AdviceFilter.doFilterInternal(AdviceFilter.java:137)
    at deployment.redacted.ear.redacted-web.war//org.apache.shiro.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:154)
    at deployment.redacted.ear.redacted-web.war//org.apache.shiro.web.servlet.ProxiedFilterChain.doFilter(ProxiedFilterChain.java:66)
    at deployment.redacted.ear.redacted-web.war//org.apache.shiro.web.servlet.AdviceFilter.executeChain(AdviceFilter.java:108)
    at deployment.redacted.ear.redacted-web.war//org.apache.shiro.web.servlet.AdviceFilter.doFilterInternal(AdviceFilter.java:137)
    at deployment.redacted.ear.redacted-web.war//org.apache.shiro.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:154)
    at deployment.redacted.ear.redacted-web.war//org.apache.shiro.web.servlet.ProxiedFilterChain.doFilter(ProxiedFilterChain.java:66)
    at deployment.redacted.ear.redacted-web.war//org.apache.shiro.web.servlet.AbstractShiroFilter.executeChain(AbstractShiroFilter.java:458)
    at deployment.redacted.ear.redacted-web.war//org.apache.shiro.web.servlet.AbstractShiroFilter$1.call(AbstractShiroFilter.java:373)
    at deployment.redacted.ear//org.apache.shiro.subject.support.SubjectCallable.doCall(SubjectCallable.java:90)
    at deployment.redacted.ear//org.apache.shiro.subject.support.SubjectCallable.call(SubjectCallable.java:83)
    at deployment.redacted.ear//org.apache.shiro.subject.support.DelegatingSubject.execute(DelegatingSubject.java:387)
    at deployment.redacted.ear.redacted-web.war//org.apache.shiro.web.servlet.AbstractShiroFilter.doFilterInternal(AbstractShiroFilter.java:370)
    at deployment.redacted.ear.redacted-web.war//org.apache.shiro.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:154)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.handlers.FilterHandler.handleRequest(FilterHandler.java:84)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.handlers.security.ServletSecurityRoleHandler.handleRequest(ServletSecurityRoleHandler.java:62)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.handlers.ServletChain$1.handleRequest(ServletChain.java:68)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.handlers.ServletDispatchingHandler.handleRequest(ServletDispatchingHandler.java:36)
    at org.wildfly.security.elytron-web.undertow-server@4.0.0.Final//org.wildfly.elytron.web.undertow.server.ElytronRunAsHandler.lambda$handleRequest$1(ElytronRunAsHandler.java:68)
    at org.wildfly.security.elytron-base@2.2.2.Final//org.wildfly.security.auth.server.FlexibleIdentityAssociation.runAsFunctionEx(FlexibleIdentityAssociation.java:103)
    at org.wildfly.security.elytron-base@2.2.2.Final//org.wildfly.security.auth.server.Scoped.runAsFunctionEx(Scoped.java:161)
    at org.wildfly.security.elytron-base@2.2.2.Final//org.wildfly.security.auth.server.Scoped.runAs(Scoped.java:73)
    at org.wildfly.security.elytron-web.undertow-server@4.0.0.Final//org.wildfly.elytron.web.undertow.server.ElytronRunAsHandler.handleRequest(ElytronRunAsHandler.java:67)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.handlers.RedirectDirHandler.handleRequest(RedirectDirHandler.java:68)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.handlers.security.SSLInformationAssociationHandler.handleRequest(SSLInformationAssociationHandler.java:117)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.handlers.security.ServletAuthenticationCallHandler.handleRequest(ServletAuthenticationCallHandler.java:57)
    at io.undertow.core@2.3.10.Final//io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
    at io.undertow.core@2.3.10.Final//io.undertow.security.handlers.AbstractConfidentialityHandler.handleRequest(AbstractConfidentialityHandler.java:46)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.handlers.security.ServletConfidentialityConstraintHandler.handleRequest(ServletConfidentialityConstraintHandler.java:64)
    at io.undertow.core@2.3.10.Final//io.undertow.security.handlers.AbstractSecurityContextAssociationHandler.handleRequest(AbstractSecurityContextAssociationHandler.java:43)
    at org.wildfly.security.elytron-web.undertow-server-servlet@4.0.0.Final//org.wildfly.elytron.web.undertow.server.servlet.CleanUpHandler.handleRequest(CleanUpHandler.java:38)
    at io.undertow.core@2.3.10.Final//io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
    at org.wildfly.extension.undertow@30.0.0.Final//org.wildfly.extension.undertow.security.jacc.JACCContextIdHandler.handleRequest(JACCContextIdHandler.java:44)
    at io.undertow.core@2.3.10.Final//io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
    at org.wildfly.extension.undertow@30.0.0.Final//org.wildfly.extension.undertow.deployment.GlobalRequestControllerHandler.handleRequest(GlobalRequestControllerHandler.java:51)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.handlers.SendErrorPageHandler.handleRequest(SendErrorPageHandler.java:52)
    at io.undertow.core@2.3.10.Final//io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.handlers.ServletInitialHandler.handleFirstRequest(ServletInitialHandler.java:276)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.handlers.ServletInitialHandler$2.call(ServletInitialHandler.java:135)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.handlers.ServletInitialHandler$2.call(ServletInitialHandler.java:132)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.core.ServletRequestContextThreadSetupAction$1.call(ServletRequestContextThreadSetupAction.java:48)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.core.ContextClassLoaderSetupAction$1.call(ContextClassLoaderSetupAction.java:43)
    at org.wildfly.extension.undertow@30.0.0.Final//org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1413)
    at org.wildfly.extension.undertow@30.0.0.Final//org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1413)
    at org.wildfly.extension.undertow@30.0.0.Final//org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1413)
    at org.wildfly.extension.undertow@30.0.0.Final//org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1413)
    at org.wildfly.extension.undertow@30.0.0.Final//org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1413)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.handlers.ServletInitialHandler.dispatchRequest(ServletInitialHandler.java:256)
    at io.undertow.servlet@2.3.10.Final//io.undertow.servlet.handlers.ServletInitialHandler$1.handleRequest(ServletInitialHandler.java:101)
    at io.undertow.core@2.3.10.Final//io.undertow.server.Connectors.executeRootHandler(Connectors.java:393)
    at io.undertow.core@2.3.10.Final//io.undertow.server.HttpServerExchange$1.run(HttpServerExchange.java:859)
    at org.jboss.threads@2.4.0.Final//org.jboss.threads.ContextClassLoaderSavingRunnable.run(ContextClassLoaderSavingRunnable.java:35)
    at org.jboss.threads@2.4.0.Final//org.jboss.threads.EnhancedQueueExecutor.safeRun(EnhancedQueueExecutor.java:1990)
    at org.jboss.threads@2.4.0.Final//org.jboss.threads.EnhancedQueueExecutor$ThreadBody.doRunTask(EnhancedQueueExecutor.java:1486)
    at org.jboss.threads@2.4.0.Final//org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1377)
    at org.jboss.xnio@3.8.11.Final//org.xnio.XnioWorker$WorkerThreadFactory$1$1.run(XnioWorker.java:1282)
    at java.base/java.lang.Thread.run(Thread.java:833)

Maybe there would be other exceptions, but I didn't test our whole application.

When I change the org.jboss.as.jsf-injection:myfaces module to include wildfly-jsf-injection-30.0.0.Final.jar and weld-jsf-5.1.2.Final.jar instead of wildfly-myfaces-injection-1.0.0.Final.jar and remove the provides tag as I did with WildFly 27, the exception goes away.

It's going to be difficult to reproduce but there's definitely something wrong. Maybe it's just an incompatibility with WildFly 30?

jasondlee commented 1 year ago

If you could provide a small reproducer, that would be super handy. It might be a while before I have time to try to cobble together one myself.

mkomko commented 1 year ago

I apologize for not replying sooner. Since the problem occurred in our huge JSF application, it's not easily possible to create a reproducer from that by removing parts of the application. Creating a reproducer from scratch would probably also take quite a bit of time, which I sadly don't have and my employer sadly won't pay. Unless you know a Maven archetype or sample project which can be deployed on WildFly and includes JSF, MyFaces, PrimeFaces, etc.?

segaura commented 4 months ago

I apologize for not replying sooner. Since the problem occurred in our huge JSF application, it's not easily possible to create a reproducer from that by removing parts of the application. Creating a reproducer from scratch would probably also take quite a bit of time, which I sadly don't have and my employer sadly won't pay. Unless you know a Maven archetype or sample project which can be deployed on WildFly and includes JSF, MyFaces, PrimeFaces, etc.?

My understanding is that you are describing primefaces-test project.

mkomko commented 4 months ago

My understanding is that you are describing primefaces-test project.

AFAIK, the primefaces-test project uses jetty to deploy the JSF application. I don't understand how it could be used to test WildFly modules.

segaura commented 4 months ago

My understanding is that you are describing primefaces-test project.

AFAIK, the primefaces-test project uses jetty to deploy the JSF application. I don't understand how it could be used to test WildFly modules.

Maybe I am wrong, but I thought you can anyway build a war from it.

mkomko commented 4 months ago

Maybe I am wrong, but I thought you can anyway build a war from it.

I'll have to check, thanks.