more than one instance
Monday, 5 August 2013 · 3 messages · last reply 7 Aug 2013
ET
Ertan Tike5 Aug 2013 00:15 #
Hi,
I'm currently using BaseX as standard server (java) mode but I planning to switch http://nxdb.codeplex.com/ . (Embedded BaseX port in .Net) My application running as IIS process which has multiple instances and threads.
My question is; is there any possible problems to access database at same time by different process/threads ? What happens when trying to access a database that is already open by another BaseX instance ?
Thanks in advance, (sorry for poor english)
Best regards,
Ertan
CG
Christian Grün7 Aug 2013 09:47 #
Hi Ertan,
Quoted text · Ertan Tike · 3 lines
> is there any possible problems to access database at same > time by different process/threads ? What happens when trying to access a > database that is already open by another BaseX instance ?
it’s no problem to access the same BaseX database by different instances, as long as no updates are performed. If an update takes place, a database is blocked for other read operations, using an exclusive file lock. You may want to have a look at our Wiki page on transactions, it gives you some more background information [1]. Please note, however, that the given information refers to the latest version of BaseX, while Nxdb was last ported from 7.2, so you may need to browse in the Wiki history, check out an older PDF version of BaseX [2], or directly talk to Dave Glick, the developer of Nxdb.
Hope this helps,
Christian
[1] http://docs.basex.org/wiki/Transaction_Management
[2] http://docs.basex.org/wiki/Documentation
ET
Ertan Tike7 Aug 2013 17:33 #
Hi thank you for reply.
If anyone interested I have recompiled BaseX 7.7 to execute in .Net environment without installation or java requirement. I have also added some components like configuration tool, running as windows service etc. Nothing special but ready to use.
You could get it from https://github.com/ertant/nbasex if needed.
On Wed, Aug 7, 2013 at 10:47 AM, Christian Grün
<christian.gruen at gmail.com>wrote:
Quoted text · Christian Grün · 22 lines
> Hi Ertan, > > > is there any possible problems to access database at same > > time by different process/threads ? What happens when trying to access a > > database that is already open by another BaseX instance ? > > it’s no problem to access the same BaseX database by different > instances, as long as no updates are performed. If an update takes > place, a database is blocked for other read operations, using an > exclusive file lock. You may want to have a look at our Wiki page on > transactions, it gives you some more background information [1]. > Please note, however, that the given information refers to the latest > version of BaseX, while Nxdb was last ported from 7.2, so you may need > to browse in the Wiki history, check out an older PDF version of BaseX > [2], or directly talk to Dave Glick, the developer of Nxdb. > > Hope this helps, > Christian > > [1] http://docs.basex.org/wiki/Transaction_Management > [2] http://docs.basex.org/wiki/Documentation >
--
Ertan TİKE
<http://www.6kare.com>
Written for BaseX 7.6, 7.7. BaseX may have changed since: please check the current documentation.
⚡Generated with XQuery