You are viewing a plain text version of this content. The canonical link for it is here.
Posted to slide-dev@jakarta.apache.org by Jacob Lund <jl...@qualiware.net> on 2004/05/27 13:29:37 UTC
deadlock with multible JDBC stores
Hi all!
Have any of you successfully configured multiple JDBC stores in domain.xml?
Have a look at the attached domain.xml file. I have defined multiple stores using TxFileStore and JDBCStore (both MySQL and SQLSever).
However it runs into a deadlock when the domain.xml definition tries to create the objectnodes for the history and files uri's.
I use tomcat 5 and latest slide.
/jacob
27 May 2004 13:27:07 - org.apache.slide.store.impl.rdbms.MySqlRDBMSAdapter - ERR
OR - SQL error 1205 on /files/project2: Deadlock found when trying to get lock;
Try restarting transaction, message from server: "Lock wait timeout exceeded; T
ry restarting transaction"
org.apache.slide.common.ServiceAccessException: Service org.apache.slide.store.i
mpl.rdbms.JDBCStore@109ea96 access error : Deadlock found when trying to get loc
k; Try restarting transaction, message from server: "Lock wait timeout exceeded
; Try restarting transaction"
at org.apache.slide.store.impl.rdbms.MySqlRDBMSAdapter.createException(M
ySqlRDBMSAdapter.java:60)
at org.apache.slide.store.impl.rdbms.StandardRDBMSAdapter.retrieveObject
(StandardRDBMSAdapter.java:356)
at org.apache.slide.store.impl.rdbms.AbstractRDBMSStore.retrieveObject(A
bstractRDBMSStore.java:588)
at org.apache.slide.store.AbstractStore.retrieveObject(AbstractStore.jav
a:595)
at org.apache.slide.store.ExtendedStore.retrieveObject(ExtendedStore.jav
a:516)
at org.apache.slide.structure.StructureImpl.create(StructureImpl.java:32
0)
at org.apache.slide.common.XMLUnmarshaller.loadObjectNode(XMLUnmarshalle
r.java:165)
at org.apache.slide.common.XMLUnmarshaller.loadObjectNode(XMLUnmarshalle
r.java:305)
at org.apache.slide.common.XMLUnmarshaller.loadObjectNode(XMLUnmarshalle
r.java:305)
at org.apache.slide.common.XMLUnmarshaller.unmarshal(XMLUnmarshaller.jav
a:97)
at org.apache.slide.common.NamespaceAccessTokenImpl.importData(Namespace
AccessTokenImpl.java:270)
at org.apache.slide.common.Namespace.loadBaseData(Namespace.java:806)
at org.apache.slide.common.Domain.initNamespace(Domain.java:828)
at org.apache.slide.common.Domain.init(Domain.java:435)
at org.apache.slide.common.Domain.selfInit(Domain.java:761)
at org.apache.slide.common.Domain.accessNamespace(Domain.java:237)
at wrappers.catalina.SlideRealm.start(SlideRealm.java:218)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1118)
at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:521
)
at org.apache.catalina.core.StandardService.start(StandardService.java:5
19)
at org.apache.catalina.core.StandardServer.start(StandardServer.java:234
5)
at org.apache.catalina.startup.Catalina.start(Catalina.java:594)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:297)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:398)
27 May 2004 13:27:07 - org.apache.slide.common.Namespace - INFO - Namespace base
configuration was already done before
27 May 2004 13:27:07 - org.apache.slide.common.Namespace - INFO - Loading namesp
ace slide configuration
27 May 2004 13:27:07 - org.apache.slide.common.Domain - ERROR - org.apache.slide
.structure.ObjectNotFoundException: No object found at /actions/read
org.apache.slide.structure.ObjectNotFoundException: No object found at /actions/
read
at org.apache.slide.store.txfile.AbstractXMLResourceDescriptor.retrieveO
bject(AbstractXMLResourceDescriptor.java:289)
at org.apache.slide.store.txfile.TxXMLFileDescriptorsStore.retrieveObjec
t(TxXMLFileDescriptorsStore.java:101)
at org.apache.slide.store.AbstractStore.retrieveObject(AbstractStore.jav
a:612)
at org.apache.slide.store.ExtendedStore.retrieveObject(ExtendedStore.jav
a:516)
at org.apache.slide.common.NamespaceConfig.getActionNode(NamespaceConfig
.java:1057)
at org.apache.slide.common.NamespaceConfig.getConfiguredNode(NamespaceCo
nfig.java:805)
at org.apache.slide.common.NamespaceConfig.initializeNamespaceConfig(Nam
espaceConfig.java:675)
at org.apache.slide.common.Namespace.loadConfiguration(Namespace.java:86
7)
at org.apache.slide.common.Domain.initNamespace(Domain.java:833)
at org.apache.slide.common.Domain.init(Domain.java:435)
at org.apache.slide.common.Domain.selfInit(Domain.java:761)
at org.apache.slide.common.Domain.accessNamespace(Domain.java:237)
at wrappers.catalina.SlideRealm.start(SlideRealm.java:218)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1118)
at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:521
)
at org.apache.catalina.core.StandardService.start(StandardService.java:5
19)
at org.apache.catalina.core.StandardServer.start(StandardServer.java:234
5)
at org.apache.catalina.startup.Catalina.start(Catalina.java:594)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:297)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:398)
27 May 2004 13:27:07 - org.apache.slide.common.Domain - INFO - Domain initializa
tion complete
java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:297)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:398)
Caused by: java.lang.NullPointerException
at org.apache.slide.common.NamespaceConfig.getParameter(NamespaceConfig.
java:569)
at org.apache.slide.common.NamespaceAccessTokenImpl.<init>(NamespaceAcce
ssTokenImpl.java:86)
at org.apache.slide.common.Domain.accessNamespace(Domain.java:246)
at wrappers.catalina.SlideRealm.start(SlideRealm.java:218)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1118)
at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:521
)
at org.apache.catalina.core.StandardService.start(StandardService.java:5
19)
at org.apache.catalina.core.StandardServer.start(StandardServer.java:234
5)
at org.apache.catalina.startup.Catalina.start(Catalina.java:594)
... 6 more
Re: deadlock with multible JDBC stores
Posted by Jacob Lund <jl...@qualiware.net>.
Well here is what I have got!
My server runs into a deadlock when I try to create objectnodes in the
domain.xml - now I need to create the history uri's in the domain.xml to
avoid errors when version-control is applied to a resource.
However it only runs into a deadlock when I add more the one objectnode to
the JDBC store. So it I just add one at a time then it works fine.
I guess it has something to do with when data is committed during the
loading of domain.xml.
/jacob
----- Original Message -----
From: "BaTien Duong" <ba...@dbgroups.com>
To: "Slide Developers Mailing List" <sl...@jakarta.apache.org>
Sent: Thursday, May 27, 2004 3:57 PM
Subject: Re: deadlock with multible JDBC stores
> Martin Holz wrote:
>
> >"Jacob Lund" <jl...@qualiware.net> writes:
> >
> >
> >
> >
> >>Have any of you successfully configured multiple JDBC stores in
domain.xml?
> >>
> >>Have a look at the attached domain.xml file. I have defined multiple
stores
> >>using TxFileStore and JDBCStore (both MySQL and SQLSever).
> >>
> >>However it runs into a deadlock when the domain.xml definition tries to
create
> >>the objectnodes for the history and files uri's.
> >>
> >>
> >
> >IIRC this was reported before for MySQL
> >See http://thread.gmane.org/gmane.comp.jakarta.slide.user/3865
> >Not sure if was ever solved. It works for me with Postgres.
> >
> >
> >
> Hello Martin:
>
> Do you mind to share your Domain.xml that work with Postgres. I was not
> able to resolve this issue yet. Here is what I have tried:
>
> <scope match="/" store='tx" /> (Tx FileDescriptorsStore)
>
> <scope match="/files/pmo" store="pmo" /> (PMO database in MySql
instance)
> <scope match="/history/pmo" store="pmo" />
> <scope match="/workspace/pmo" store="pmo" />
> <scope match="/workingresource/pmo" store="pmo" />
>
> This works fine. But when i introduce store testCom that connects to a
> separate database TESTCOM in the same MySql instance, i get a deadlock.
> The idea is to isolate each project in separate database. When the
> project is finished, all we need is a backup of the database and takes
> it out of the service.
>
> <scope match="/files/testCom" store="testCom" /> (TESTCOM database in
> the same MySql instance)
> <scope match="/history/testCom" store="testCom" />
> <scope match="/workspace/testCom" store="testCom" />
> <scope match="/workingresource/testCom" store="testCom" />
>
> I have tried with both MySql 4.0.18 and 4.1.1. At this current status, i
> have not tried with different MySql instances or different RDBMS.
>
> Thanks.
>
> BaTien
> DBGROUPS
>
> >Martin
> >
> >
> >
> >---------------------------------------------------------------------
> >To unsubscribe, e-mail: slide-dev-unsubscribe@jakarta.apache.org
> >For additional commands, e-mail: slide-dev-help@jakarta.apache.org
> >
> >.
> >
> >
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: slide-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: slide-dev-help@jakarta.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: slide-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: slide-dev-help@jakarta.apache.org
Re: deadlock with multible JDBC stores
Posted by BaTien Duong <ba...@dbgroups.com>.
Martin Holz wrote:
>"Jacob Lund" <jl...@qualiware.net> writes:
>
>
>
>
>>Have any of you successfully configured multiple JDBC stores in domain.xml?
>>
>>Have a look at the attached domain.xml file. I have defined multiple stores
>>using TxFileStore and JDBCStore (both MySQL and SQLSever).
>>
>>However it runs into a deadlock when the domain.xml definition tries to create
>>the objectnodes for the history and files uri's.
>>
>>
>
>IIRC this was reported before for MySQL
>See http://thread.gmane.org/gmane.comp.jakarta.slide.user/3865
>Not sure if was ever solved. It works for me with Postgres.
>
>
>
Hello Martin:
Do you mind to share your Domain.xml that work with Postgres. I was not
able to resolve this issue yet. Here is what I have tried:
<scope match="/" store='tx" /> (Tx FileDescriptorsStore)
<scope match="/files/pmo" store="pmo" /> (PMO database in MySql instance)
<scope match="/history/pmo" store="pmo" />
<scope match="/workspace/pmo" store="pmo" />
<scope match="/workingresource/pmo" store="pmo" />
This works fine. But when i introduce store testCom that connects to a
separate database TESTCOM in the same MySql instance, i get a deadlock.
The idea is to isolate each project in separate database. When the
project is finished, all we need is a backup of the database and takes
it out of the service.
<scope match="/files/testCom" store="testCom" /> (TESTCOM database in
the same MySql instance)
<scope match="/history/testCom" store="testCom" />
<scope match="/workspace/testCom" store="testCom" />
<scope match="/workingresource/testCom" store="testCom" />
I have tried with both MySql 4.0.18 and 4.1.1. At this current status, i
have not tried with different MySql instances or different RDBMS.
Thanks.
BaTien
DBGROUPS
>Martin
>
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: slide-dev-unsubscribe@jakarta.apache.org
>For additional commands, e-mail: slide-dev-help@jakarta.apache.org
>
>.
>
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: slide-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: slide-dev-help@jakarta.apache.org
Re: deadlock with multible JDBC stores
Posted by Martin Holz <ho...@fiz-chemie.de>.
"Jacob Lund" <jl...@qualiware.net> writes:
> Have any of you successfully configured multiple JDBC stores in domain.xml?
>
> Have a look at the attached domain.xml file. I have defined multiple stores
> using TxFileStore and JDBCStore (both MySQL and SQLSever).
>
> However it runs into a deadlock when the domain.xml definition tries to create
> the objectnodes for the history and files uri's.
IIRC this was reported before for MySQL
See http://thread.gmane.org/gmane.comp.jakarta.slide.user/3865
Not sure if was ever solved. It works for me with Postgres.
Martin
---------------------------------------------------------------------
To unsubscribe, e-mail: slide-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: slide-dev-help@jakarta.apache.org