3 Replies Latest reply on Jul 25, 2014 9:48 AM by Steven Hawkins

    hibernate-on-top-of-teiid example - user not entitled to action error

    Kevin Tiren Newbie

      Hi,

       

      I've been trying to run the Teiid hibernate example following the steps from teiid-quickstarts/hibernate-on-top-of-teiid at master · teiid/teiid-quickstarts · GitHub

      When I try to open the url to access the application http://localhost:8080/hibernate-on-top-of-teiid/. I get the following errors:

       

      JBWEB000065: HTTP Status 500 - WELD-000049 Unable to invoke [method] @PostConstruct public com.client.quickstart.hibernate4.data.ProductListProducer.retrieveAllProductsOrderedByName() on com.client.quickstart.hibernate4.data.ProductListProducer@b503b23


      JBWEB000309: type JBWEB000066: Exception report

      JBWEB000068: message WELD-000049 Unable to invoke [method] @PostConstruct public com.client.quickstart.hibernate4.data.ProductListProducer.retrieveAllProductsOrderedByName() on com.client.quickstart.hibernate4.data.ProductListProducer@b503b23

      JBWEB000069: description JBWEB000145: The server encountered an internal error that prevented it from fulfilling this request.

      JBWEB000070: exception

      javax.servlet.ServletException: WELD-000049 Unable to invoke [method] @PostConstruct public com.client.quickstart.hibernate4.data.ProductListProducer.retrieveAllProductsOrderedByName() on com.client.quickstart.hibernate4.data.ProductListProducer@b503b23 javax.faces.webapp.FacesServlet.service(FacesServlet.java:606) 

      JBWEB000071: root cause

      org.jboss.weld.exceptions.WeldException: WELD-000049 Unable to invoke [method] @PostConstruct public com.client.quickstart.hibernate4.data.ProductListProducer.retrieveAllProductsOrderedByName() on com.client.quickstart.hibernate4.data.ProductListProducer@b503b23 org.jboss.weld.bean.AbstractClassBean.defaultPostConstruct(AbstractClassBean.java:404) org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.postConstruct(ManagedBean.java:174) org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:294) org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:608) org.jboss.weld.bean.AbstractReceiverBean.getReceiver(AbstractReceiverBean.java:77) org.jboss.weld.bean.AbstractProducerBean$AbstractProducer.produce(AbstractProducerBean.java:317) org.jboss.weld.bean.AbstractProducerBean.create(AbstractProducerBean.java:307) org.jboss.weld.context.unbound.DependentContextImpl.get(DependentContextImpl.java:68) org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:608) org.jboss.weld.el.AbstractWeldELResolver.lookup(AbstractWeldELResolver.java:127) org.jboss.weld.el.AbstractWeldELResolver.getValue(AbstractWeldELResolver.java:96) org.jboss.as.weld.webtier.jsf.ForwardingELResolver.getValue(ForwardingELResolver.java:46) javax.el.CompositeELResolver.getValue(CompositeELResolver.java:175) com.sun.faces.el.DemuxCompositeELResolver._getValue(DemuxCompositeELResolver.java:176) com.sun.faces.el.DemuxCompositeELResolver.getValue(DemuxCompositeELResolver.java:203) org.apache.el.parser.AstIdentifier.getValue(AstIdentifier.java:72) org.apache.el.parser.AstEmpty.getValue(AstEmpty.java:47) org.apache.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:189) org.jboss.weld.el.WeldValueExpression.getValue(WeldValueExpression.java:50) com.sun.faces.facelets.el.TagValueExpression.getValue(TagValueExpression.java:109) javax.faces.component.ComponentStateHelper.eval(ComponentStateHelper.java:194) javax.faces.component.UIComponentBase.isRendered(UIComponentBase.java:419) javax.faces.component.UIComponent.encodeAll(UIComponent.java:1773) javax.faces.component.UIComponent.encodeAll(UIComponent.java:1782) javax.faces.component.UIComponent.encodeAll(UIComponent.java:1782) com.sun.faces.application.view.FaceletViewHandlingStrategy.renderView(FaceletViewHandlingStrategy.java:439) com.sun.faces.application.view.MultiViewHandler.renderView(MultiViewHandler.java:124) javax.faces.application.ViewHandlerWrapper.renderView(ViewHandlerWrapper.java:286) com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:120) com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101) com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:139) javax.faces.webapp.FacesServlet.service(FacesServlet.java:594) 

      JBWEB000071: root cause

      java.lang.reflect.InvocationTargetException sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) java.lang.reflect.Method.invoke(Method.java:606) org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:267) org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:52) org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:137) org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:263) org.jboss.weld.introspector.jlr.WeldMethodImpl.invoke(WeldMethodImpl.java:174) org.jboss.weld.bean.AbstractClassBean.defaultPostConstruct(AbstractClassBean.java:402) org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.postConstruct(ManagedBean.java:174) org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:294) org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:608) org.jboss.weld.bean.AbstractReceiverBean.getReceiver(AbstractReceiverBean.java:77) org.jboss.weld.bean.AbstractProducerBean$AbstractProducer.produce(AbstractProducerBean.java:317) org.jboss.weld.bean.AbstractProducerBean.create(AbstractProducerBean.java:307) org.jboss.weld.context.unbound.DependentContextImpl.get(DependentContextImpl.java:68) org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:608) org.jboss.weld.el.AbstractWeldELResolver.lookup(AbstractWeldELResolver.java:127) org.jboss.weld.el.AbstractWeldELResolver.getValue(AbstractWeldELResolver.java:96) org.jboss.as.weld.webtier.jsf.ForwardingELResolver.getValue(ForwardingELResolver.java:46) javax.el.CompositeELResolver.getValue(CompositeELResolver.java:175) com.sun.faces.el.DemuxCompositeELResolver._getValue(DemuxCompositeELResolver.java:176) com.sun.faces.el.DemuxCompositeELResolver.getValue(DemuxCompositeELResolver.java:203) org.apache.el.parser.AstIdentifier.getValue(AstIdentifier.java:72) org.apache.el.parser.AstEmpty.getValue(AstEmpty.java:47) org.apache.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:189) org.jboss.weld.el.WeldValueExpression.getValue(WeldValueExpression.java:50) com.sun.faces.facelets.el.TagValueExpression.getValue(TagValueExpression.java:109) javax.faces.component.ComponentStateHelper.eval(ComponentStateHelper.java:194) javax.faces.component.UIComponentBase.isRendered(UIComponentBase.java:419) javax.faces.component.UIComponent.encodeAll(UIComponent.java:1773) javax.faces.component.UIComponent.encodeAll(UIComponent.java:1782) javax.faces.component.UIComponent.encodeAll(UIComponent.java:1782) com.sun.faces.application.view.FaceletViewHandlingStrategy.renderView(FaceletViewHandlingStrategy.java:439) com.sun.faces.application.view.MultiViewHandler.renderView(MultiViewHandler.java:124) javax.faces.application.ViewHandlerWrapper.renderView(ViewHandlerWrapper.java:286) com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:120) com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101) com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:139) javax.faces.webapp.FacesServlet.service(FacesServlet.java:594) 

      JBWEB000071: root cause

      org.hibernate.exception.GenericJDBCException: could not extract ResultSet org.hibernate.exception.internal.StandardSQLExceptionConverter.convert(StandardSQLExceptionConverter.java:54) org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:125) org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:110) org.hibernate.engine.jdbc.internal.ResultSetReturnImpl.extract(ResultSetReturnImpl.java:53) org.hibernate.loader.Loader.getResultSet(Loader.java:2031) org.hibernate.loader.Loader.executeQueryStatement(Loader.java:1832) org.hibernate.loader.Loader.executeQueryStatement(Loader.java:1811) org.hibernate.loader.Loader.doQuery(Loader.java:899) org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:341) org.hibernate.loader.Loader.doList(Loader.java:2516) org.hibernate.loader.Loader.doList(Loader.java:2502) org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2332) org.hibernate.loader.Loader.list(Loader.java:2327) org.hibernate.loader.criteria.CriteriaLoader.list(CriteriaLoader.java:124) org.hibernate.internal.SessionImpl.list(SessionImpl.java:1620) org.hibernate.internal.CriteriaImpl.list(CriteriaImpl.java:374) com.client.quickstart.hibernate4.data.ProductListProducer.retrieveAllProductsOrderedByName(ProductListProducer.java:48) sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) java.lang.reflect.Method.invoke(Method.java:606) org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:267) org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:52) org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:137) org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:263) org.jboss.weld.introspector.jlr.WeldMethodImpl.invoke(WeldMethodImpl.java:174) org.jboss.weld.bean.AbstractClassBean.defaultPostConstruct(AbstractClassBean.java:402) org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.postConstruct(ManagedBean.java:174) org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:294) org.jboss.weld.context.AbstractContext.get(AbstractContext.java:103) org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:608) org.jboss.weld.bean.AbstractReceiverBean.getReceiver(AbstractReceiverBean.java:77) org.jboss.weld.bean.AbstractProducerBean$AbstractProducer.produce(AbstractProducerBean.java:317) org.jboss.weld.bean.AbstractProducerBean.create(AbstractProducerBean.java:307) org.jboss.weld.context.unbound.DependentContextImpl.get(DependentContextImpl.java:68) org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:608) org.jboss.weld.el.AbstractWeldELResolver.lookup(AbstractWeldELResolver.java:127) org.jboss.weld.el.AbstractWeldELResolver.getValue(AbstractWeldELResolver.java:96) org.jboss.as.weld.webtier.jsf.ForwardingELResolver.getValue(ForwardingELResolver.java:46) javax.el.CompositeELResolver.getValue(CompositeELResolver.java:175) com.sun.faces.el.DemuxCompositeELResolver._getValue(DemuxCompositeELResolver.java:176) com.sun.faces.el.DemuxCompositeELResolver.getValue(DemuxCompositeELResolver.java:203) org.apache.el.parser.AstIdentifier.getValue(AstIdentifier.java:72) org.apache.el.parser.AstEmpty.getValue(AstEmpty.java:47) org.apache.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:189) org.jboss.weld.el.WeldValueExpression.getValue(WeldValueExpression.java:50) com.sun.faces.facelets.el.TagValueExpression.getValue(TagValueExpression.java:109) javax.faces.component.ComponentStateHelper.eval(ComponentStateHelper.java:194) javax.faces.component.UIComponentBase.isRendered(UIComponentBase.java:419) javax.faces.component.UIComponent.encodeAll(UIComponent.java:1773) javax.faces.component.UIComponent.encodeAll(UIComponent.java:1782) javax.faces.component.UIComponent.encodeAll(UIComponent.java:1782) com.sun.faces.application.view.FaceletViewHandlingStrategy.renderView(FaceletViewHandlingStrategy.java:439) com.sun.faces.application.view.MultiViewHandler.renderView(MultiViewHandler.java:124) javax.faces.application.ViewHandlerWrapper.renderView(ViewHandlerWrapper.java:286) com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:120) com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101) com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:139) javax.faces.webapp.FacesServlet.service(FacesServlet.java:594) 

      JBWEB000071: root cause

      org.teiid.jdbc.TeiidSQLException: TEIID30492 User <user> is not entitled to action <READ> for 1 or more of the groups/elements/procedures. org.teiid.jdbc.TeiidSQLException.create(TeiidSQLException.java:135) org.teiid.jdbc.TeiidSQLException.create(TeiidSQLException.java:71) org.teiid.jdbc.StatementImpl.postReceiveResults(StatementImpl.java:667) org.teiid.jdbc.StatementImpl.access$100(StatementImpl.java:63) org.teiid.jdbc.StatementImpl$2.onCompletion(StatementImpl.java:515) org.teiid.client.util.ResultsFuture.done(ResultsFuture.java:135) org.teiid.client.util.ResultsFuture.access$200(ResultsFuture.java:40) org.teiid.client.util.ResultsFuture$1.receiveResults(ResultsFuture.java:79) org.teiid.dqp.internal.process.RequestWorkItem.sendError(RequestWorkItem.java:993) org.teiid.dqp.internal.process.RequestWorkItem.close(RequestWorkItem.java:552) org.teiid.dqp.internal.process.RequestWorkItem.process(RequestWorkItem.java:352) org.teiid.dqp.internal.process.AbstractWorkItem.run(AbstractWorkItem.java:51) org.teiid.dqp.internal.process.RequestWorkItem.run(RequestWorkItem.java:254) org.teiid.dqp.internal.process.DQPWorkContext.runInContext(DQPWorkContext.java:274) org.teiid.dqp.internal.process.ThreadReuseExecutor$RunnableWrapper.run(ThreadReuseExecutor.java:119) org.teiid.dqp.internal.process.ThreadReuseExecutor$3.run(ThreadReuseExecutor.java:214) java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) java.lang.Thread.run(Thread.java:744) 

      JBWEB000071: root cause

      org.teiid.api.exception.query.QueryValidatorException: TEIID30492 User <user> is not entitled to action <READ> for 1 or more of the groups/elements/procedures. org.teiid.dqp.internal.process.Request.validateWithVisitor(Request.java:305) org.teiid.dqp.internal.process.DefaultAuthorizationValidator.validate(DefaultAuthorizationValidator.java:98) org.teiid.dqp.internal.process.Request.validateAccess(Request.java:454) org.teiid.dqp.internal.process.Request.generatePlan(Request.java:373) org.teiid.dqp.internal.process.PreparedStatementRequest.generatePlan(PreparedStatementRequest.java:115) org.teiid.dqp.internal.process.Request.processRequest(Request.java:435) org.teiid.dqp.internal.process.PreparedStatementRequest.processRequest(PreparedStatementRequest.java:289) org.teiid.dqp.internal.process.RequestWorkItem.processNew(RequestWorkItem.java:609) org.teiid.dqp.internal.process.RequestWorkItem.process(RequestWorkItem.java:315) org.teiid.dqp.internal.process.AbstractWorkItem.run(AbstractWorkItem.java:51) org.teiid.dqp.internal.process.RequestWorkItem.run(RequestWorkItem.java:254) org.teiid.dqp.internal.process.DQPWorkContext.runInContext(DQPWorkContext.java:274) org.teiid.dqp.internal.process.ThreadReuseExecutor$RunnableWrapper.run(ThreadReuseExecutor.java:119) org.teiid.dqp.internal.process.ThreadReuseExecutor$3.run(ThreadReuseExecutor.java:214) java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) java.lang.Thread.run(Thread.java:744) 

      JBWEB000072: note JBWEB000073: The full stack trace of the root cause is available in the JBoss Web/7.2.0.Final logs.


      JBoss Web/7.2.0.Final

       

      What could be wrong?

       

      I appreciate the help!