[Beginners Corner] - linking configuration files to applications
by gmesturini
Scenario:
Appserver: JBOSS 4.0.5 GA (but i can change for a latest if things I need aren't available in this version).
application-a.ear
config-dir-a
- settings.properties
application-b.ear
config-dir-b
- settings.properties
application-a and application-b must be installed on the same application server. they have their own configuration directories containing configuration files: directories have different name, while files have the same name. I need to separate the loader of each application to point them on the right configuration files. I've tried to use SAR, but it seems to load the same configuration file for each application (maybe the last loaded file).
Files cannot be archived in a JAR in order to let customers to change them without recompile or repacking. To be more clear in explanation, what I would like to do is something like the shared-library mechanism of IBM WebSphere, where you can link a shared-library to an application, being sure that files contained will be visible only to the attached application.
Any suggestion?
Thank you very much
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4035880#4035880
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4035880
19 years
[Persistence, JBoss/CMP, Hibernate, Database] - Deadlock problems with Hibernate/Spring/MS-SQL
by yuvalg
Hi all,
We just started to test our system with some modest users load and we are experiencing some critical database access related problems.
Our application runs on Jboss 4.0.4 on a Red-Hat Linux machine (but we also see the problems at our development boxes on windows).
We use JDK 5 and Hibernate 3.2 (with annotions), our MS-SQL 2005 database runs (of course) on a windows machine, :)
We also use a POJO development model with Spring 2.0 that takes care of transaction demarcation (that plugs into Jboss's JTA).
We use the latest jdbc driver from Microsoft.
Some general data: we monitored the datasource connection-pool and it doesnt seem to leak, the memory
doesnt seem to be leaking either also and the cpu (both at the appserver and database machine) is very much un-utilized.
Top exceptions on the score board:
com.microsoft.sqlserver.jdbc.SQLServerException: Server failed to resume the transaction
com.microsoft.sqlserver.jdbc.SQLServerException: Transaction (Process ID 100) was deadlocked on lock resources with another process and has been chosen as the deadlock victim. Rerun the transaction.
Our exception trace:
2007-04-05 17:12:08,858 ERROR [org.hibernate.util.JDBCExceptionReporter] Transaction (Process ID 100) was deadlocked on lock resources with another process and has been chosen as the deadlock victim. Rerun the transaction.
2007-04-05 17:12:08,858 WARN [org.hibernate.util.JDBCExceptionReporter] SQL Error: 1205, SQLState: 40001
2007-04-05 17:12:08,858 ERROR [org.hibernate.util.JDBCExceptionReporter] Transaction (Process ID 59) was deadlocked on lock resources with another process and has been chosen as the deadlock victim. Rerun the transaction.
2007-04-05 17:12:08,858 WARN [org.hibernate.util.JDBCExceptionReporter] SQL Error: 1205, SQLState: 40001
2007-04-05 17:12:08,858 ERROR [org.hibernate.util.JDBCExceptionReporter] Transaction (Process ID 77) was deadlocked on lock resources with another process and has been chosen as the deadlock victim. Rerun the transaction.
2007-04-05 17:12:08,860 WARN [org.hibernate.util.JDBCExceptionReporter] SQL Error: 1205, SQLState: 40001
2007-04-05 17:12:08,858 ERROR [someproject.ticket.service.impl.TicketServiceImpl] [getCountTicketsPerGame] Failed
someproject.common.exceptions.DaoException: org.hibernate.exception.LockAcquisitionException: could not execute query
at someproject.ticket.dao.impl.TicketDaoHibernateImpl.getCountTicketsPerGame(Unknown Source)
at someproject.ticket.service.impl.TicketServiceImpl.getCountTicketsPerGame(Unknown Source)
at sun.reflect.GeneratedMethodAccessor432.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:318)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:203)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:162)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:107)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:185)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:209)
at $Proxy74.getCountTicketsPerGame(Unknown Source)
at sun.reflect.GeneratedMethodAccessor432.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:318)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:203)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:162)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:107)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:185)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:209)
at $Proxy75.getCountTicketsPerGame(Unknown Source)
at sun.reflect.GeneratedMethodAccessor432.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:318)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:203)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:162)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:107)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:185)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:209)
at $Proxy75.getCountTicketsPerGame(Unknown Source)
at someproject.game.view.handler.TicketViewHandler.prepareTicketLeftMenu(Unknown Source)
at sun.reflect.GeneratedMethodAccessor516.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at uk.ltd.getahead.dwr.impl.ExecuteQuery.execute(ExecuteQuery.java:248)
at uk.ltd.getahead.dwr.impl.DefaultExecProcessor.handle(DefaultExecProcessor.java:48)
at uk.ltd.getahead.dwr.impl.DefaultProcessor.handle(DefaultProcessor.java:81)
at uk.ltd.getahead.dwr.AbstractDWRServlet.doPost(AbstractDWRServlet.java:162)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:175)
at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:74)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
at java.lang.Thread.run(Thread.java:595)
Caused by: org.hibernate.exception.LockAcquisitionException: could not execute query
at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:82)
at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:43)
at org.hibernate.loader.Loader.doList(Loader.java:2147)
at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2028)
at org.hibernate.loader.Loader.list(Loader.java:2023)
at org.hibernate.loader.hql.QueryLoader.list(QueryLoader.java:393)
at org.hibernate.hql.ast.QueryTranslatorImpl.list(QueryTranslatorImpl.java:338)
at org.hibernate.engine.query.HQLQueryPlan.performList(HQLQueryPlan.java:172)
at org.hibernate.impl.SessionImpl.list(SessionImpl.java:1121)
at org.hibernate.impl.QueryImpl.list(QueryImpl.java:79)
at org.hibernate.impl.AbstractQueryImpl.uniqueResult(AbstractQueryImpl.java:780)
... 60 more
Caused by: com.microsoft.sqlserver.jdbc.SQLServerException: Transaction (Process ID 100) was deadlocked on lock resources with another process and has been chosen as the deadlock victim. Rerun the transaction.
at com.microsoft.sqlserver.jdbc.SQLServerException.makeFromDatabaseError(Unknown Source)
at com.microsoft.sqlserver.jdbc.IOBuffer.processPackets(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerStatement.buildNextRowset(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerStatement.getNextResult(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement.getPrepExecResponse(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement.doExecutePreparedStatement(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement$PreparedStatementExecutionRequest.executeStatement(Unknown Source)
at com.microsoft.sqlserver.jdbc.CancelableRequest.execute(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerConnection.executeRequest(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement.executeQuery(Unknown Source)
at org.jboss.resource.adapter.jdbc.WrappedPreparedStatement.executeQuery(WrappedPreparedStatement.java:236)
at org.hibernate.jdbc.AbstractBatcher.getResultSet(AbstractBatcher.java:186)
at org.hibernate.loader.Loader.getResultSet(Loader.java:1668)
at org.hibernate.loader.Loader.doQuery(Loader.java:662)
at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:224)
at org.hibernate.loader.Loader.doList(Loader.java:2144)
... 68 more
Other exception we receive:
2007-04-10 06:04:24,228 ERROR [someproject.game.service.impl.TicketAuctionServiceImpl] [closeAuctionsSequence] Failed to fetch list of auctions to close
someproject.common.exceptions.DaoException: org.hibernate.exception.SQLGrammarException: could not execute query
at someproject.game.dao.impl.TicketAuctionDaoHibernateImpl.readAuctionsToClose(Unknown Source)
at someproject.game.service.impl.TicketAuctionServiceImpl.closeAuctionsSequence(Unknown Source)
at sun.reflect.GeneratedMethodAccessor513.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:318)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:203)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:162)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:107)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:185)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:209)
at $Proxy77.closeAuctionsSequence(Unknown Source)
at sun.reflect.GeneratedMethodAccessor513.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:318)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:203)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:162)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:107)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:185)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:209)
at $Proxy78.closeAuctionsSequence(Unknown Source)
at sun.reflect.GeneratedMethodAccessor513.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:318)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:203)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:162)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:107)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:185)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:209)
at $Proxy80.closeAuctionsSequence(Unknown Source)
at someproject.game.CloseAuctionJob.execute(Unknown Source)
at org.quartz.core.JobRunShell.run(JobRunShell.java:202)
at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:529)
Caused by: org.hibernate.exception.SQLGrammarException: could not execute query
at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:67)
at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:43)
at org.hibernate.loader.Loader.doList(Loader.java:2147)
at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2028)
at org.hibernate.loader.Loader.list(Loader.java:2023)
at org.hibernate.loader.hql.QueryLoader.list(QueryLoader.java:393)
at org.hibernate.hql.ast.QueryTranslatorImpl.list(QueryTranslatorImpl.java:338)
at org.hibernate.engine.query.HQLQueryPlan.performList(HQLQueryPlan.java:172)
at org.hibernate.impl.SessionImpl.list(SessionImpl.java:1121)
at org.hibernate.impl.QueryImpl.list(QueryImpl.java:79)
... 35 more
Caused by: com.microsoft.sqlserver.jdbc.SQLServerException: Server failed to resume the transaction, desc: 3d00000010.
at com.microsoft.sqlserver.jdbc.SQLServerException.makeFromDatabaseError(Unknown Source)
at com.microsoft.sqlserver.jdbc.IOBuffer.processPackets(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement.getPrepExecResponse(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement.doExecutePreparedStatement(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement$PreparedStatementExecutionRequest.executeStatement(Unknown Source)
at com.microsoft.sqlserver.jdbc.CancelableRequest.execute(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerConnection.executeRequest(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement.executeQuery(Unknown Source)
at org.jboss.resource.adapter.jdbc.CachedPreparedStatement.executeQuery(CachedPreparedStatement.java:90)
at org.jboss.resource.adapter.jdbc.WrappedPreparedStatement.executeQuery(WrappedPreparedStatement.java:236)
at org.hibernate.jdbc.AbstractBatcher.getResultSet(AbstractBatcher.java:186)
at org.hibernate.loader.Loader.getResultSet(Loader.java:1668)
at org.hibernate.loader.Loader.doQuery(Loader.java:662)
at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:224)
at org.hibernate.loader.Loader.doList(Loader.java:2144)
... 42 more
2007-04-10 06:04:24,230 ERROR [someproject.game.CloseAuctionJob] [execute] Failed
someproject.common.exceptions.ApplicationException: someproject.common.exceptions.DaoException: org.hibernate.exception.SQLGrammarException: could not execute query
at someproject.game.service.impl.TicketAuctionServiceImpl.closeAuctionsSequence(Unknown Source)
at sun.reflect.GeneratedMethodAccessor513.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:318)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:203)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:162)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:107)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:185)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:209)
at $Proxy77.closeAuctionsSequence(Unknown Source)
at sun.reflect.GeneratedMethodAccessor513.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:318)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:203)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:162)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:107)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:185)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:209)
at $Proxy78.closeAuctionsSequence(Unknown Source)
at sun.reflect.GeneratedMethodAccessor513.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:318)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:203)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:162)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:107)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:185)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:209)
at $Proxy80.closeAuctionsSequence(Unknown Source)
at someproject.game.CloseAuctionJob.execute(Unknown Source)
at org.quartz.core.JobRunShell.run(JobRunShell.java:202)
at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:529)
Caused by: someproject.common.exceptions.DaoException: org.hibernate.exception.SQLGrammarException: could not execute query
at someproject.game.dao.impl.TicketAuctionDaoHibernateImpl.readAuctionsToClose(Unknown Source)
... 34 more
Caused by: org.hibernate.exception.SQLGrammarException: could not execute query
at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:67)
at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:43)
at org.hibernate.loader.Loader.doList(Loader.java:2147)
at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2028)
at org.hibernate.loader.Loader.list(Loader.java:2023)
at org.hibernate.loader.hql.QueryLoader.list(QueryLoader.java:393)
at org.hibernate.hql.ast.QueryTranslatorImpl.list(QueryTranslatorImpl.java:338)
at org.hibernate.engine.query.HQLQueryPlan.performList(HQLQueryPlan.java:172)
at org.hibernate.impl.SessionImpl.list(SessionImpl.java:1121)
at org.hibernate.impl.QueryImpl.list(QueryImpl.java:79)
... 35 more
Caused by: com.microsoft.sqlserver.jdbc.SQLServerException: Server failed to resume the transaction, desc: 3d00000010.
at com.microsoft.sqlserver.jdbc.SQLServerException.makeFromDatabaseError(Unknown Source)
at com.microsoft.sqlserver.jdbc.IOBuffer.processPackets(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement.getPrepExecResponse(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement.doExecutePreparedStatement(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement$PreparedStatementExecutionRequest.executeStatement(Unknown Source)
at com.microsoft.sqlserver.jdbc.CancelableRequest.execute(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerConnection.executeRequest(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement.executeQuery(Unknown Source)
at org.jboss.resource.adapter.jdbc.CachedPreparedStatement.executeQuery(CachedPreparedStatement.java:90)
at org.jboss.resource.adapter.jdbc.WrappedPreparedStatement.executeQuery(WrappedPreparedStatement.java:236)
at org.hibernate.jdbc.AbstractBatcher.getResultSet(AbstractBatcher.java:186)
at org.hibernate.loader.Loader.getResultSet(Loader.java:1668)
at org.hibernate.loader.Loader.doQuery(Loader.java:662)
at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:224)
at org.hibernate.loader.Loader.doList(Loader.java:2144)
... 42 more
2007-04-10 06:05:00,010 DEBUG [someproject.game.UpdateGameOnlineInfoJob] [execute] Staring
2007-04-10 06:05:00,011 DEBUG [someproject.common.dao.impl.GenericDaoHibernateImpl] [updateGameOnlineInfo] query:UPDATE GOI SET GOI.Numer_Of_Tickets=tmp_GOI.tickets, GOI.Prize_Pool=tmp_GOI.pool FROM (SELECT G.Game_Id, count(T.Ticket_Id) as tickets ,count(T.Ticket_Id)*GA.Ticket_Price*(1-GA.Game_Profit) as pool FROM GAME_ONLINE_INFO G join GAME GA on G.Game_Id = GA.Game_Id and GA.Status_Id=5 left join TICKET T on g.Game_Id=T.Game_Id and T.Type_Id=1 and T.Status_Id=1 GROUP BY G.Game_Id,GA.Ticket_Price ,GA.Game_Profit) tmp_GOI, GAME_ONLINE_INFO GOI WHERE GOI.Game_Id=tmp_GOI.Game_Id
2007-04-10 06:05:00,012 ERROR [someproject.game.service.impl.GameServiceExtendedImpl] Publish games Error:
someproject.common.exceptions.DaoException: org.hibernate.exception.SQLGrammarException: could not execute update query
at someproject.game.dao.impl.GameExtendedDaoHibernateImpl.publishGames(Unknown Source)
at someproject.game.service.impl.GameServiceExtendedImpl.publishGames(Unknown Source)
at sun.reflect.GeneratedMethodAccessor688.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:318)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:203)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:162)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:107)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:185)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:209)
at $Proxy102.publishGames(Unknown Source)
at sun.reflect.GeneratedMethodAccessor688.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:318)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:203)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:162)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:107)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:185)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:209)
at $Proxy103.publishGames(Unknown Source)
at sun.reflect.GeneratedMethodAccessor688.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:318)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:203)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:162)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:107)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:185)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:209)
at $Proxy109.publishGames(Unknown Source)
at someproject.game.PublishGamesJob.execute(Unknown Source)
at org.quartz.core.JobRunShell.run(JobRunShell.java:202)
at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:529)
Caused by: org.hibernate.exception.SQLGrammarException: could not execute update query
at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:67)
at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:43)
at org.hibernate.hql.ast.exec.BasicExecutor.execute(BasicExecutor.java:84)
at org.hibernate.hql.ast.QueryTranslatorImpl.executeUpdate(QueryTranslatorImpl.java:396)
at org.hibernate.engine.query.HQLQueryPlan.performExecuteUpdate(HQLQueryPlan.java:259)
at org.hibernate.impl.SessionImpl.executeUpdate(SessionImpl.java:1141)
at org.hibernate.impl.QueryImpl.executeUpdate(QueryImpl.java:94)
... 35 more
Caused by: com.microsoft.sqlserver.jdbc.SQLServerException: Server failed to resume the transaction, desc: 3d00000010.
at com.microsoft.sqlserver.jdbc.SQLServerException.makeFromDatabaseError(Unknown Source)
at com.microsoft.sqlserver.jdbc.IOBuffer.processPackets(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement.getPrepExecResponse(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement.doExecutePreparedStatement(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement$PreparedStatementExecutionRequest.executeStatement(Unknown Source)
at com.microsoft.sqlserver.jdbc.CancelableRequest.execute(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerConnection.executeRequest(Unknown Source)
at com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement.executeUpdate(Unknown Source)
at org.jboss.resource.adapter.jdbc.CachedPreparedStatement.executeUpdate(CachedPreparedStatement.java:95)
at org.jboss.resource.adapter.jdbc.WrappedPreparedStatement.executeUpdate(WrappedPreparedStatement.java:251)
at org.hibernate.hql.ast.exec.BasicExecutor.execute(BasicExecutor.java:75)
... 39 more
2007-04-10 06:05:18,009 DEBUG [someproject.common.OnLoadListener] No rule found for view /include/header.jsp
Any help will be greatly appreciated!
Thanks,
Yuval.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4035875#4035875
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4035875
19 years
[JBoss Seam] - Re: Bugs in 1.2.1 blog example
by RobJellinghaus
OK, so it turns out that the spurious pre in the first blog post is due to a spurious backquote in import.sql:
insert into blogentry (blog_name, id, title, excerpt, body, date) values ('JBoss Seam Blog', 'seamtext', 'Introducing Seam Text', ...+'<table style="border:1px solid blue;"><tr><td>Foo</td><td>Bar</td></tr></table>`', '2007-01-18 4:00')
Take out that final backquote, and the bad pre tag vanishes.
So the question is, should SeamText be smart enough to close dangling elements? And is it a bug that the main index.xhtml page isn't being served as application/xhtml+xml under Firefox?
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4035872#4035872
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4035872
19 years
[JBoss Seam] - Bugs in 1.2.1 blog example
by RobJellinghaus
I'm playing with the blog example (working on integrating some Google Web Toolkit functionality into it, which I hope to submit back to Seam a la Todd Smart's ajax4jsf booking integration).
I'm noticing a couple of squirrelly things under JDK 1.5.0_06 and Tomcat 5.5.12. This is with a brand new install of Seam 1.2.1 and a clean webapps directory, after "ant" at Seam root and "ant deploy.tomcat" in examples/blog.
First and most important, there's a spurious HTML tag emitted by SeamText right after the little sample one-cell table in the first post:
<table style="border:1px solid blue;"><tr><td>Foo</td><td>Bar</td></tr></table><pre>
The final pre is a bug.
The thing is, though, that you don't actually see this bug in the app itself. Because despite the fact that index.xhtml and template.xhtml declare themselves as having a DOCTYPE of XHTML, they aren't actually being served as application/xhtml+xml to Firefox. I can see in Firefox that they are being rendered as text/html. So the broken tag isn't obvious because Firefox ignores bad tags like that with text/html.
I ran into this because in my own example (for reasons I have yet to fully understand), the doctype *is* being heeded and the pages *are* getting served to Firefox as application/xhtml+xml... which fails to render because it's expecting a /pre but encounters a /div.
However, it turns out that the Atom feed page (index.xml) IS getting served as XML... and is broken! Not only is the spurious pre tag present, but there isn't a closing /feed tag at the end. View source on the index.xml Atom feed, and paste into an XML text editor, to see these bad tags.
I am able to fix the unclosed feed tag by swapping the f:view and feed elements (e.g. putting the f:view outermost, with the feed just inside it), which AFAIK is better Facelets style anyway.
Shall I file JIRA entries for these?
Cheers!
Rob
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4035870#4035870
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4035870
19 years