Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [dtp-dev] Re: DTP support for SQLite DB

My mistake. I was referencing the same driver jar from two different driver definitions. When I switched it over to use the same driver definition as the one that connected successfully, it worked.
 
So it does work for a shared driver definition. Just not if the jar is used by two separate driver definitions.
 
Sorry to add to the confusion.
 
--Fitz

Brian Fitzpatrick
Senior Software Engineer/DTP Committer
Sybase, Inc.

-----dtp-dev-bounces@xxxxxxxxxxx wrote: -----

To: DTP development mailing list <dtp-dev@xxxxxxxxxxx>
From: rcernich@xxxxxxxxxx
Sent by: dtp-dev-bounces@xxxxxxxxxxx
Date: 11/08/2006 01:26PM
Subject: Re: [dtp-dev] Re: DTP support for SQLite DB

Hey Brian,


> Just as an aside, I just tested in a workspace where I have two
> different SQLite database files. The driver loads successfully the
> first time for either of my two profiles. And I can connect and
> disconnect from that one just fine. But I am not allowed to connect
> to a second database. I am getting an unsatisified link error.
>
> Unable to load sqlite: java.lang.UnsatisfiedLinkError: Native
> Library C:\Program Files\Java\j2re1.4.2_12\bin\sqlite_jni.dll
> already loaded in another classloader
>

If you are seeing this error, then we haven't fixed the problem.  This was
the error listed in the original bug report.  We need to investigate what
is going on with the classloaders.  Try setting a breakpoint in the
DriverInstance.getClassLoader() to see if a new classloader is being
created.  It may be that the old classloader has been marked for deletion,
but not yet reclaimed.  It could also be that the JVM doesn't release the
library, regardless of whether or not the classloader has been reclaimed,
or that the library hasn't been unloaded.  I'm not sure what the specified
behavior is for these cases.

Another simple test would be to store the classloader in a plain old member
variable instead of using a SoftReference.  If that fixes things, perhaps
we should leave the fancier stuff for a future release.

Thanks,
Rob

_______________________________________________
dtp-dev mailing list
dtp-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/dtp-dev



Back to the top