You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-user@db.apache.org by jatintrivedi <ja...@gmail.com> on 2006/11/23 13:03:09 UTC
Derby multiple connections issue
I have SQL Explorer plugin in Eclipse through which I can view the derby.
However when my apllication hosted on Apache (and debuggin in Eclipse) is
accessing derby database, I am not able to connect to SQL Explorer through
Eclipse and vice-versa.
There could be some issue with multiple connections to Derby
--
View this message in context: http://www.nabble.com/Derby-multiple-connections-issue-tf2692186.html#a7507293
Sent from the Apache Derby Users mailing list archive at Nabble.com.
Re: Derby multiple connections issue
Posted by John Embretsen <Jo...@Sun.COM>.
jatintrivedi wrote:
> I have SQL Explorer plugin in Eclipse through which I can view the derby.
> However when my apllication hosted on Apache (and debuggin in Eclipse) is
> accessing derby database, I am not able to connect to SQL Explorer through
> Eclipse and vice-versa.
> There could be some issue with multiple connections to Derby
This is just a wild guess, since I do not have experience with the Eclipse
plugin, nor am I sure what you mean by "hosted on Apache", but it could be
because Derby does not allow a database to be booted from two different JVMs at
the same time. If you use the embedded driver both places, this would be the case.
This is from the Developer's guide,
http://db.apache.org/derby/docs/dev/devguide/cdevdvlp20458.html:
<quote>
Derby allows you to boot databases that are not in the system directory. While
this might seem more convenient, check that you do not boot the same database
with two JVMs. If you need to access a single database from more than one JVM,
you will need to put a server solution in place. You can allow multiple JVMs
that need to access that database to connect to the server. The Derby Network
Server is provided as a server solution. See the Derby Server and Administration
Guide for more information on the Network Server.
</quote>
In other words, a Derby database can be accessed from two JVMs if you use a
client/server solution. If you use the embedded driver without starting the
server, you can only access a database from one JVM at a time. However, multiple
connections from one JVM is supported in all cases.
--
John