[opencms-dev] JPA driver for 7.5.2

Georgi Naplatanov gosho at oles.biz
Wed Aug 4 12:13:55 CEST 2010


Hello Yves.

Thank you for this bug report.

There is workaround. You can use "Context Menu/History" dialog to 
restore online version of resource.

Best regards
Georgi

Yves Glodt wrote:
> Hi Gerogi,
> 
> I found a small bug with the jpa-version. I get an exception everytime I 
> do "Undo changes", as follows:
> 
> 26 Jul 2010 23:01:25,128 ERROR [rg.opencms.workplace.CmsDialog:1452] The 
> workplace dialog caused an error.
> org.opencms.file.CmsVfsException: Error undoing changes of resource 
> "/demo_en/intro.html".
>         at org.opencms.db.CmsDbContext.throwException(CmsDbContext.java:264)
>         at org.opencms.db.jpa.CmsDbContext.report(CmsDbContext.java:107)
>         at 
> org.opencms.db.CmsSecurityManager.undoChanges(CmsSecurityManager.java:4876)
>         at 
> org.opencms.file.types.A_CmsResourceType.undoChanges(A_CmsResourceType.java:804)
>         at org.opencms.file.CmsObject.undoChanges(CmsObject.java:4189)
>         at 
> org.opencms.workplace.commons.CmsUndoChanges.performDialogOperation(CmsUndoChanges.java:489)
>         at 
> org.opencms.workplace.commons.CmsUndoChanges.actionUndoChanges(CmsUndoChanges.java:217)
>         at 
> org.apache.jsp.WEB_002dINF.jsp.offline.system.workplace.commons.undochanges_jsp._jspService(undochanges_jsp.java:137)
>         at 
> org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
>         at 
> org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:377)
>         at 
> org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:313)
>         at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:260)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
>         at 
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>         at 
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>         at 
> org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:646)
>         at 
> org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:551)
>         at 
> org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:488)
>         at 
> org.opencms.flex.CmsFlexRequestDispatcher.includeExternal(CmsFlexRequestDispatcher.java:194)
>         at 
> org.opencms.flex.CmsFlexRequestDispatcher.include(CmsFlexRequestDispatcher.java:169)
>         at org.opencms.loader.CmsJspLoader.service(CmsJspLoader.java:555)
>         at 
> org.opencms.flex.CmsFlexRequestDispatcher.includeInternalWithCache(CmsFlexRequestDispatcher.java:423)
>         at 
> org.opencms.flex.CmsFlexRequestDispatcher.include(CmsFlexRequestDispatcher.java:173)
>         at 
> org.opencms.loader.CmsJspLoader.dispatchJsp(CmsJspLoader.java:829)
>         at org.opencms.loader.CmsJspLoader.load(CmsJspLoader.java:512)
>         at 
> org.opencms.loader.CmsResourceManager.loadResource(CmsResourceManager.java:1052)
>         at org.opencms.main.OpenCmsCore.showResource(OpenCmsCore.java:1504)
>         at org.opencms.main.OpenCmsServlet.doGet(OpenCmsServlet.java:153)
>         at org.opencms.main.OpenCmsServlet.doPost(OpenCmsServlet.java:166)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:637)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
>         at 
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>         at 
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>         at 
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
>         at 
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>         at 
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>         at 
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>         at 
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>         at 
> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298)
>         at 
> org.apache.coyote.http11.Http11AprProcessor.process(Http11AprProcessor.java:861)
>         at 
> org.apache.coyote.http11.Http11AprProtocol$Http11ConnectionHandler.process(Http11AprProtocol.java:579)
>         at 
> org.apache.tomcat.util.net.AprEndpoint$Worker.run(AprEndpoint.java:1584)
>         at java.lang.Thread.run(Thread.java:619)
> Caused by: java.lang.NullPointerException
>         at 
> org.opencms.db.CmsPublishedResource.<init>(CmsPublishedResource.java:149)
>         at 
> org.opencms.db.CmsPublishedResource.<init>(CmsPublishedResource.java:138)
>         at 
> org.opencms.search.CmsSearchManager$CmsSearchOfflineHandler.reIndexResources(CmsSearchManager.java:262)
>         at 
> org.opencms.search.CmsSearchManager$CmsSearchOfflineHandler.cmsEvent(CmsSearchManager.java:173)
>         at 
> org.opencms.main.CmsEventManager.fireEventHandler(CmsEventManager.java:203)
>         at 
> org.opencms.main.CmsEventManager.fireEvent(CmsEventManager.java:126)
>         at org.opencms.main.OpenCms.fireCmsEvent(OpenCms.java:156)
>         at 
> org.opencms.db.jpa.CmsVfsDriver.createResource(CmsVfsDriver.java:757)
>         at 
> org.opencms.db.CmsDriverManager.createResource(CmsDriverManager.java:1747)
>         at 
> org.opencms.db.CmsDriverManager.undoContentChanges(CmsDriverManager.java:9544)
>         at 
> org.opencms.db.CmsDriverManager.undoChanges(CmsDriverManager.java:7679)
>         at 
> org.opencms.db.CmsSecurityManager.undoChanges(CmsSecurityManager.java:4874)
> 
> 
> On 26 May 2010 09:45, Yves Glodt <yg at mind.lu <mailto:yg at mind.lu>> wrote:
> 
>     I think I found an issue in my code.
> 
>     I have a jsp which logs in a user (CmsObject.loginUser()), gets a
>     list of image resources, and displays 3 by random.
>     Now I can imagine the deadlock comes when several people hit the
>     site concurrently.
> 
>     I should find a better way to dislpay random resources I guess.
> 
>     best regards,
>     yves
> 
> 
>     On 21 May 2010 09:58, Yves Glodt <yg at mind.lu <mailto:yg at mind.lu>> wrote:
> 
>         Hi!
> 
>         I think there should be no simultaneous logins... But I can not
>         be sure if some people left a browser somewhere open with a
>         logged session...
> 
>         Good news about jpa 2.0, I will wait for that. Hopefully I can
>         upgrade 7.5.2 by just replacing the relevant jars... :-)
> 
>         yves
> 
> 
>         On 21 May 2010 09:50, Georgi Naplatanov <gosho at oles.biz
>         <mailto:gosho at oles.biz>> wrote:
> 
>             Hello Yves.
> 
>             In your case if there are not simultaneous logins with the
>             same user
>             name, it sounds like a bug.
> 
>             These days OpenJPA 2.0 is available and I will build OpenCms
>             with this
>             version of OpenJPA which contains a lot of bug fixes.
> 
>             Best regards
>             Georgi
> 
>             Yves Glodt wrote:
>              > Hi Georgi,
>              >
>              > I use only the workplace here.
>              >
>              > On 20 May 2010 14:40, Georgi Naplatanov <gosho at oles.biz
>             <mailto:gosho at oles.biz>
>              > <mailto:gosho at oles.biz <mailto:gosho at oles.biz>>> wrote:
>              >
>              >     Hello Yves.
>              >
>              >     OpenCms updates user last login when user login on.
>              >
>              >     Do you use cms shell or this exception occurs when
>             you use workplace ?
>              >
>              >     Best regards
>              >     Georgi
>              >
>              >     Yves Glodt wrote:
>              >      > Hi Georgii,
>              >      >
>              >      > I am using the jpa-builds with Firebird 2.1 quite
>             intensively, and
>              >      > frequently see this in the logs:
>              >      >
>              >      > SEVERE: Servlet.service() for servlet jsp threw
>             exception
>              >      > org.apache.openjpa.lib.jdbc.ReportingSQLException:
>             GDS Exception.
>              >      > 335544336. deadlock
>              >      > update conflicts with concurrent update
>              >      > No message for code 335544878 found.
>              >      > null {prepstmnt 1344045115 UPDATE CMS_USERS SET
>             USER_LASTLOGIN =
>              >     ? WHERE
>              >      > USER_ID = ? [params=(long) 1274353716094, (String)
>              >      > ea551c31-xxxx-yyyy-zzzz-1234567890]}
>             [code=335544336, state=HY000]
>              >      >
>              >      > Do you have an idea where these deadlocks come from?
>              >      > If you need more details, let me know!
>              >      >
>              >      > best regards,
>              >      > Yves
>              >      >
>              >      > On 21 January 2010 16:17, Achim Westermann
>              >     <achim.westermann at questico.de
>             <mailto:achim.westermann at questico.de>
>             <mailto:achim.westermann at questico.de
>             <mailto:achim.westermann at questico.de>>
>              >      > <mailto:achim.westermann at questico.de
>             <mailto:achim.westermann at questico.de>
>              >     <mailto:achim.westermann at questico.de
>             <mailto:achim.westermann at questico.de>>>> wrote:
>              >      >
>              >      >     Hi Georgi,
>              >      >
>              >      >     that was quick!
>              >      >
>              >      >     thx for sharing your work.
>              >      >
>              >      >     Achim
>              >      >
>              >      >     Georgi Naplatanov wrote:
>              >      >      > binary -
>              >      >      >
>              >      >
>              >    
>             http://os.oles.biz/opencms/jpa-driver/opencms_7.5.2-jpa-2010-01-21.zip
>              >      >      >
>              >      >      > source code -
>              >     https://opencms-jpa.oles.biz/opencmsjpa/branches/7.5.2/
>              >      >      >
>              >      >      > Best regards
>              >      >      > Georgi
>              >      >      >
> 
> 
> 
> ------------------------------------------------------------------------
> 
> 
> _______________________________________________
> This mail is sent to you from the opencms-dev mailing list
> To change your list options, or to unsubscribe from the list, please visit
> http://lists.opencms.org/mailman/listinfo/opencms-dev




More information about the opencms-dev mailing list