Navigation

Inscrivez-vous gratuitement
pour pouvoir participer, suivre les réponses en temps réel, voter pour les messages, poser vos propres questions et recevoir la newsletter

Glassfish et Payara Java Discussion :

glassfish EJB conteneur erreur


Sujet :

Glassfish et Payara Java

  1. #1
    Membre du Club
    glassfish EJB conteneur erreur
    bonjour

    j'ai développé une application web avec primefaces, tout va bien sauf que dans la partie d'authentification des fois et au hasard j'ai l'erreur suivante
    Code :Sélectionner tout -Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
    60
    61
    62
    63
    64
    65
    66
    67
    68
    69
    70
    71
    72
    73
    74
    75
    76
    77
    78
    79
    80
    81
    82
    83
    84
    85
    86
    87
    88
    89
    90
    91
    92
    93
    94
    95
    96
    97
    98
    99
    100
    101
    102
    103
    104
    105
    106
    107
    108
    109
    110
    111
    112
    113
    114
    115
    116
    117
    118
    119
    120
    121
    122
    123
    124
    125
    126
    127
    128
    129
    130
    131
    132
    133
    134
    135
    136
    137
    138
    139
    140
    141
    142
    143
    144
    145
    146
    147
    148
    149
    150
    151
    152
    153
    154
    155
    156
    157
    158
    159
    160
    161
    162
    163
    164
    165
    166
    167
    168
    169
    170
    171
     
    [glassfish 4.1] [WARNING] [AS-EJB-00056] [javax.enterprise.ejb.container] [tid: _ThreadID=37 _ThreadName=http-listener-2(3)] [timeMillis: 1445422923538] [levelValue: 900] [[
      A system exception occurred during an invocation on EJB DaoUtils, method: public java.util.List Daos.DaoUtils.loadUsers()]]
     
    [2015-10-21T11:22:03.538+0100] [glassfish 4.1] [WARNING] [] [javax.enterprise.ejb.container] [tid: _ThreadID=37 _ThreadName=http-listener-2(3)] [timeMillis: 1445422923538] [levelValue: 900] [[
     
    javax.ejb.TransactionRolledbackLocalException: Client's transaction aborted
    	at com.sun.ejb.containers.EJBContainerTransactionManager.useClientTx(EJBContainerTransactionManager.java:357)
    	at com.sun.ejb.containers.EJBContainerTransactionManager.preInvokeTx(EJBContainerTransactionManager.java:251)
    	at com.sun.ejb.containers.BaseContainer.preInvokeTx(BaseContainer.java:4524)
    	at com.sun.ejb.containers.BaseContainer.preInvoke(BaseContainer.java:1986)
    	at com.sun.ejb.containers.EJBLocalObjectInvocationHandler.invoke(EJBLocalObjectInvocationHandler.java:210)
    	at com.sun.ejb.containers.EJBLocalObjectInvocationHandlerDelegate.invoke(EJBLocalObjectInvocationHandlerDelegate.java:88)
    	at com.sun.proxy.$Proxy282.loadUsers(Unknown Source)
    	at Daos.__EJB31_Generated__DaoUtils__Intf____Bean__.loadUsers(Unknown Source)
    	at beans.Lists.getUsers(Lists.java:156)
    	at sun.reflect.GeneratedMethodAccessor881.invoke(Unknown Source)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:483)
    	at javax.el.BeanELResolver.getValue(BeanELResolver.java:363)
    	at com.sun.faces.el.DemuxCompositeELResolver._getValue(DemuxCompositeELResolver.java:176)
    	at com.sun.faces.el.DemuxCompositeELResolver.getValue(DemuxCompositeELResolver.java:203)
    	at com.sun.el.parser.AstValue.getValue(AstValue.java:140)
    	at com.sun.el.parser.AstValue.getValue(AstValue.java:204)
    	at com.sun.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:226)
    	at org.jboss.weld.el.WeldValueExpression.getValue(WeldValueExpression.java:50)
    	at com.sun.faces.facelets.el.TagValueExpression.getValue(TagValueExpression.java:109)
    	at javax.faces.component.ComponentStateHelper.eval(ComponentStateHelper.java:194)
    	at javax.faces.component.ComponentStateHelper.eval(ComponentStateHelper.java:182)
    	at javax.faces.component.UISelectItems.getValue(UISelectItems.java:129)
    	at org.primefaces.renderkit.InputRenderer.getSelectItems(InputRenderer.java:55)
    	at org.primefaces.component.selectonemenu.SelectOneMenuRenderer.encodeMarkup(SelectOneMenuRenderer.java:71)
    	at org.primefaces.component.selectonemenu.SelectOneMenuRenderer.encodeEnd(SelectOneMenuRenderer.java:65)
    	at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:919)
    	at com.sun.faces.renderkit.html_basic.HtmlBasicRenderer.encodeRecursive(HtmlBasicRenderer.java:312)
    	at com.sun.faces.renderkit.html_basic.GridRenderer.renderRow(GridRenderer.java:185)
    	at com.sun.faces.renderkit.html_basic.GridRenderer.encodeChildren(GridRenderer.java:129)
    	at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:889)
    	at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1856)
    	at javax.faces.render.Renderer.encodeChildren(Renderer.java:176)
    	at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:889)
    	at org.primefaces.renderkit.CoreRenderer.renderChild(CoreRenderer.java:70)
    	at org.primefaces.renderkit.CoreRenderer.renderChildren(CoreRenderer.java:57)
    	at org.primefaces.renderkit.CoreRenderer.renderChild(CoreRenderer.java:72)
    	at org.primefaces.renderkit.CoreRenderer.renderChildren(CoreRenderer.java:57)
    	at org.primefaces.component.layout.LayoutUnitRenderer.encodeEnd(LayoutUnitRenderer.java:51)
    	at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:919)
    	at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1863)
    	at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1859)
    	at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1859)
    	at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1859)
    	at com.sun.faces.application.view.FaceletViewHandlingStrategy.renderView(FaceletViewHandlingStrategy.java:456)
    	at com.sun.faces.application.view.MultiViewHandler.renderView(MultiViewHandler.java:133)
    	at javax.faces.application.ViewHandlerWrapper.renderView(ViewHandlerWrapper.java:337)
    	at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:120)
    	at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101)
    	at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:219)
    	at javax.faces.webapp.FacesServlet.service(FacesServlet.java:647)
    	at org.apache.catalina.core.StandardWrapper.service(StandardWrapper.java:1682)
    	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:344)
    	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214)
    	at beans.usersessionFilter.doFilter(usersessionFilter.java:61)
    	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:256)
    	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214)
    	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:316)
    	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:160)
    	at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:734)
    	at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:673)
    	at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:99)
    	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:174)
    	at org.apache.catalina.connector.CoyoteAdapter.doService(CoyoteAdapter.java:415)
    	at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:282)
    	at com.sun.enterprise.v3.services.impl.ContainerMapper$HttpHandlerCallable.call(ContainerMapper.java:459)
    	at com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:167)
    	at org.glassfish.grizzly.http.server.HttpHandler.runService(HttpHandler.java:201)
    	at org.glassfish.grizzly.http.server.HttpHandler.doHandle(HttpHandler.java:175)
    	at org.glassfish.grizzly.http.server.HttpServerFilter.handleRead(HttpServerFilter.java:235)
    	at org.glassfish.grizzly.filterchain.ExecutorResolver$9.execute(ExecutorResolver.java:119)
    	at org.glassfish.grizzly.filterchain.DefaultFilterChain.executeFilter(DefaultFilterChain.java:283)
    	at org.glassfish.grizzly.filterchain.DefaultFilterChain.executeChainPart(DefaultFilterChain.java:200)
    	at org.glassfish.grizzly.filterchain.DefaultFilterChain.execute(DefaultFilterChain.java:132)
    	at org.glassfish.grizzly.filterchain.DefaultFilterChain.process(DefaultFilterChain.java:111)
    	at org.glassfish.grizzly.ProcessorExecutor.execute(ProcessorExecutor.java:77)
    	at org.glassfish.grizzly.nio.transport.TCPNIOTransport.fireIOEvent(TCPNIOTransport.java:561)
    	at org.glassfish.grizzly.strategies.AbstractIOStrategy.fireIOEvent(AbstractIOStrategy.java:112)
    	at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy.run0(WorkerThreadIOStrategy.java:117)
    	at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy.access$100(WorkerThreadIOStrategy.java:56)
    	at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy$WorkerThreadRunnable.run(WorkerThreadIOStrategy.java:137)
    	at org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:565)
    	at org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.run(AbstractThreadPool.java:545)
    	at java.lang.Thread.run(Thread.java:745)
    ]]
     
    [2015-10-21T11:22:03.539+0100] [glassfish 4.1] [SEVERE] [] [javax.enterprise.resource.webcontainer.jsf.application] [tid: _ThreadID=37 _ThreadName=http-listener-2(3)] [timeMillis: 1445422923539] [levelValue: 1000] [[
      Error Rendering View[/dgmda/index.xhtml]
    javax.el.ELException: /dgmda/loginForm.xhtml @24,72 value="#{lists.users}": javax.ejb.EJBTransactionRolledbackException
    	at com.sun.faces.facelets.el.TagValueExpression.getValue(TagValueExpression.java:114)
    	at javax.faces.component.ComponentStateHelper.eval(ComponentStateHelper.java:194)
    	at javax.faces.component.ComponentStateHelper.eval(ComponentStateHelper.java:182)
    	at javax.faces.component.UISelectItems.getValue(UISelectItems.java:129)
    	at org.primefaces.renderkit.InputRenderer.getSelectItems(InputRenderer.java:55)
    	at org.primefaces.component.selectonemenu.SelectOneMenuRenderer.encodeMarkup(SelectOneMenuRenderer.java:71)
    	at org.primefaces.component.selectonemenu.SelectOneMenuRenderer.encodeEnd(SelectOneMenuRenderer.java:65)
    	at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:919)
    	at com.sun.faces.renderkit.html_basic.HtmlBasicRenderer.encodeRecursive(HtmlBasicRenderer.java:312)
    	at com.sun.faces.renderkit.html_basic.GridRenderer.renderRow(GridRenderer.java:185)
    	at com.sun.faces.renderkit.html_basic.GridRenderer.encodeChildren(GridRenderer.java:129)
    	at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:889)
    	at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1856)
    	at javax.faces.render.Renderer.encodeChildren(Renderer.java:176)
    	at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:889)
    	at org.primefaces.renderkit.CoreRenderer.renderChild(CoreRenderer.java:70)
    	at org.primefaces.renderkit.CoreRenderer.renderChildren(CoreRenderer.java:57)
    	at org.primefaces.renderkit.CoreRenderer.renderChild(CoreRenderer.java:72)
    	at org.primefaces.renderkit.CoreRenderer.renderChildren(CoreRenderer.java:57)
    	at org.primefaces.component.layout.LayoutUnitRenderer.encodeEnd(LayoutUnitRenderer.java:51)
    	at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:919)
    	at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1863)
    	at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1859)
    	at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1859)
    	at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1859)
    	at com.sun.faces.application.view.FaceletViewHandlingStrategy.renderView(FaceletViewHandlingStrategy.java:456)
    	at com.sun.faces.application.view.MultiViewHandler.renderView(MultiViewHandler.java:133)
    	at javax.faces.application.ViewHandlerWrapper.renderView(ViewHandlerWrapper.java:337)
    	at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:120)
    	at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101)
    	at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:219)
    	at javax.faces.webapp.FacesServlet.service(FacesServlet.java:647)
    	at org.apache.catalina.core.StandardWrapper.service(StandardWrapper.java:1682)
    	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:344)
    	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214)
    	at beans.usersessionFilter.doFilter(usersessionFilter.java:61)
    	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:256)
    	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214)
    	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:316)
    	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:160)
    	at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:734)
    	at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:673)
    	at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:99)
    	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:174)
    	at org.apache.catalina.connector.CoyoteAdapter.doService(CoyoteAdapter.java:415)
    	at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:282)
    	at com.sun.enterprise.v3.services.impl.ContainerMapper$HttpHandlerCallable.call(ContainerMapper.java:459)
    	at com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:167)
    	at org.glassfish.grizzly.http.server.HttpHandler.runService(HttpHandler.java:201)
    	at org.glassfish.grizzly.http.server.HttpHandler.doHandle(HttpHandler.java:175)
    	at org.glassfish.grizzly.http.server.HttpServerFilter.handleRead(HttpServerFilter.java:235)
    	at org.glassfish.grizzly.filterchain.ExecutorResolver$9.execute(ExecutorResolver.java:119)
    	at org.glassfish.grizzly.filterchain.DefaultFilterChain.executeFilter(DefaultFilterChain.java:283)
    	at org.glassfish.grizzly.filterchain.DefaultFilterChain.executeChainPart(DefaultFilterChain.java:200)
    	at org.glassfish.grizzly.filterchain.DefaultFilterChain.execute(DefaultFilterChain.java:132)
    	at org.glassfish.grizzly.filterchain.DefaultFilterChain.process(DefaultFilterChain.java:111)
    	at org.glassfish.grizzly.ProcessorExecutor.execute(ProcessorExecutor.java:77)
    	at org.glassfish.grizzly.nio.transport.TCPNIOTransport.fireIOEvent(TCPNIOTransport.java:561)
    	at org.glassfish.grizzly.strategies.AbstractIOStrategy.fireIOEvent(AbstractIOStrategy.java:112)
    	at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy.run0(WorkerThreadIOStrategy.java:117)
    	at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy.access$100(WorkerThreadIOStrategy.java:56)
    	at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy$WorkerThreadRunnable.run(WorkerThreadIOStrategy.java:137)
    	at org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:565)
    	at org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.run(AbstractThreadPool.java:545)
    	at java.lang.Thread.run(Thread.java:745)
    Caused by: javax.el.ELException: javax.ejb.EJBTransactionRolledbackException
    	at javax.el.BeanELResolver.getValue(BeanELResolver.java:368)
    	at com.sun.faces.el.DemuxCompositeELResolver._getValue(DemuxCompositeELResolver.java:176)
    	at com.sun.faces.el.DemuxCompositeELResolver.getValue(DemuxCompositeELResolver.java:203)
    	at com.sun.el.parser.AstValue.getValue(AstValue.java:140)
    	at com.sun.el.parser.AstValue.getValue(AstValue.java:204)
    	at com.sun.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:226)
    	at org.jboss.weld.el.WeldValueExpression.getValue(WeldValueExpression.java:50)
    	at com.sun.faces.facelets.el.TagValueExpression.getValue(TagValueExpression.java:109)
    	... 64 more

    la méthode loadUsers() est une méthode pour récupérer la liste des utilisateurs de la base de donné
    Code :Sélectionner tout -Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
     
    @Stateful
    public class DaoUtils {
     
        private Connection DaoUconn;
        private DataSources.UtilisateurDts utilds;
     
        public DaoUtils() {
     
            utilds = DataSources.UtilisateurDts.getInstance();
     
        }
     
        public List<User> loadUsers() {
     
            User user = null;
     
            ArrayList<User> list_users = new ArrayList();
            if (utilds == null) {
                return null;
            }
            try {
                DaoUconn = utilds.getCon();
            } catch (SQLException ex) {
                Logger.getLogger(DaoUtils.class.getName()).log(Level.SEVERE, null, ex);
            }
     
            try {
                CallableStatement pst = DaoUconn.prepareCall("{call  dbo.UsersSelect()}");
                ResultSet rst = pst.executeQuery();
                while (rst.next()) {
                    user = new User(rst.getString("Code_User"), rst.getString("Username"), rst.getString("UserEmail"));
                    list_user(user);
                }
            } catch (SQLException ex) {
                Logger.getLogger(DaoUtils.class.getName()).log(Level.SEVERE, null, ex);
            } finally {
                if (DaoUconn != null) {
                    try {
                        DaoUconn.close();
                    } catch (SQLException ex) {
                        System.err.print(ex);
                    }
                }
            }
            return list_users 
        }
    }

    l'application est hébergé sur un serveur sous windows server 2008
    et glassFish 4.1 open source edition
    merci d'avance pour votre aide

  2. #2
    Membre expérimenté
    mode fonctionnement
    Bonjour,

    En mode dev ou production ?
    Je ne comprends pas tu n'utilises pas JPA ?

    Olivier
    Architecte destructurant,
    be cool, be free

    Il nous reste Debian bien sûr