Re: A concrete deadlock problem

Serge Huber <[email protected]>
Newsgroups gmane.comp.cms.jahia.devel
Message-ID <[email protected]>
Hi Benjamin,

Again a lot of very good questions :) Sometimes I wish you wouldn't 
understand Jahia so well :)

Anyway the problems you are experiencing are the reasons we didn't turn 
on transactions on by default. It is known to cause problems with 
certain databases. We had identified problems with MS SQL Server, but 
didn't test transactions with Oracle, so it seems you have found another 
database that it problematic.

[email protected] wrote:

>
> To solve the problem for now I can only think of using Oracle 
> SEQUENCES instead of the jahia_autoids table. The SEQUENCES do not 
> cause locks, but unfortunately this is Oracle specific. Another 
> solution would be to call the "UPDATE jahia_autoids" in a separate 
> transaction. I don't know yet, if this is possible at all.

Well there is a service that handles the generation of the identifiers 
using the jahia_autoids table. You could, if you needed to, do an Oracle 
specific implementation of it, but of course this isn't the prefered 
solution.

>
> Why do you need this JAHIA_LINKs anyway? Is it possible to do insert 
> the JAHIA_LINKS when releasing the new page?
> Do you have any other suggestions how to solve this issue? 

The JAHIA_LINKs are used to track which content objects are displayed by 
which pages. Basically, for a given container lists, we track in the 
JAHIA_LINK table, all the pages that display this container list, so 
that when it's content is modified, we can lookup it's uses in the 
JAHIA_LINK table to know which pages to flush in the HTML cache. The 
JAHIA_LINK tables is also used for category associations, and in future 
versions of Jahia, for more general object association management.

The update in JAHIA_LINK you are experiencing I think comes from the 
loading of JahiaPageFields. It might be possible to defer this write, 
for example by inscribing all the updates in a request attribute and 
then processing them in a block at the end of the data processing (as it 
is currently being done for absoluteContainerList references in 
org.jahia.engines.core.Core_Engine.postProcessCore). This might do the 
trick.

Regards,
  Serge Huber.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.