[fdo-users] .net Wrapper quirks

Greg Boone greg.boone at autodesk.com
Fri Apr 4 10:16:33 EDT 2008


This is the primary cause of the defect as it results in an excessive number of SQLite resources being instantiated and used before enough resources are freed by the garbage collector. As a work-around, calling Close()/Dispose() should resolve the issue. However, we will also try and make a fix in the SDF provider so that these steps are not explicitly necessary.

One last point, you still should explicitly assign the result of Execute to a Feature Reader so that the garbage collection can happen at an appropriate time.

Greg

-----Original Message-----
From: fdo-users-bounces at lists.osgeo.org [mailto:fdo-users-bounces at lists.osgeo.org] On Behalf Of Jackie Ng
Sent: Friday, April 04, 2008 2:38 AM
To: fdo-users at lists.osgeo.org
Subject: Re: [fdo-users] .net Wrapper quirks


I just looked at the unit test code for the ticket, and noticed I might have
been doing something wrong.

I forgot that IInsert::Execute() returns an IFeatureReader and so I haven't
been closing and disposing them.

One (of many?) possible cause(s)?

- Jackie


Jackie Ng wrote:
>
> Hi All,
>
> I've been writing .net code that copies data from one FDO connection to
> another (Doing a series of IInsert::Execute() calls from an IFeatureReader
> ). In my adventures using the FDO .net wrapper, I have encountered the
> following problems at random:
>
> - System.AccessViolationExceptions ("Attempted to read or write protected
> memory. This is often an indication that other memory is corrupt") thrown
> at OSGeo.FDO.Runtime.Disposable.Finalize() (Target Site: void
> ReleaseUnmanagedObject() )
> - C++ pure virtual function call errors.
> - Memory allocation failed errors.
>
> Is there some quirks with the .net wrapper that I should be aware of? As
> OSGeo.FDO.Runtime.Disposable implements IDisposable, I've been wrapping
> nearly every FDO object used inside using() blocks. Could this be a cause?
>
> I am using .net wrappers for FDO 3.3.0
>
> - Jackie
>
>
>

--
View this message in context: http://www.nabble.com/.net-Wrapper-quirks-tp16318694s18162p16485877.html
Sent from the fdo-users mailing list archive at Nabble.com.

_______________________________________________
fdo-users mailing list
fdo-users at lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/fdo-users


More information about the fdo-users mailing list