Which reminds me I never seen in javadocs how the datastore api is supposed to behave under concurrent access, which, if not stated explicitly, it seems to mean it is _not_ thread safe and client code should take care?
This may be something to make clear, one option or the other, as it seems we were making implementations thread safe on an as needed basis (arcsde, shapefile), others benefit of its underlying technology (jdbc), yet for implementors (including us) it would be good to know: - if the api is meant to be thread safe - other details like if XXXFactory.createDataStore() should return the same instance for the same parameters, and XXXDataStore.getFeatureSource(typeName) returns the same instance for a given feature type, etc. I know both cases are left to implementors preference, yet explicitly stating how the api should behave under concurrent access may change the preference. Also it seems reasonable for the api to require being thread safe, so I guess my point is just it is not clear enough. Gabriel. On Thursday 14 February 2008 03:40:04 am Jody Garnett wrote: > The shapefile read/write support is known to deadlock on 2.4.0, a > rewrite has been made for trunk (ie GeoTools 2.5) and we are waiting on > community review and feedback. > > Looking at the test it makes use of wait(500) a fair bit - trying to > sleep for a set amount of time and verify that the lock has indeed been > released. Since the actual functionality of wait is a bit random on > different operating systems we have taken to making a loop and checking > that the system clock did in fact change (wait is only a request often > it can return before the system clock has managed to tick over; darn > computers getting faster and breaking my tests!) > > Cheers, > Jody > > > Hello all, > > > > I am new to this list and to geotools. In attempting to build the > > 2.4.0 sources (downloaded yesterday) on Mac OSX I receive the > > following test failure: > > > > Running org.geotools.data.shapefile.LockTest > > Tests run: 3, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 3.014 > > sec <<< FAILURE! > > > > org.geotools.data.shapefile.LockTest.txt: > > ------------------------------------------------------------------------- > >------ Test set: org.geotools.data.shapefile.LockTest > > ------------------------------------------------------------------------- > >------ Tests run: 3, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: > > 3.015 sec <<< FAILURE! > > testLockRead(org.geotools.data.shapefile.LockTest) Time elapsed: > > 1.006 sec <<< FAILURE! > > junit.framework.AssertionFailedError > > at junit.framework.Assert.fail(Assert.java:47) > > at junit.framework.Assert.assertTrue(Assert.java:20) > > at junit.framework.Assert.assertTrue(Assert.java:27) > > at > > org.geotools.data.shapefile.LockTest.testLockRead(LockTest.java:178) > > > > I'm assuming this is happening to others (?). Any suggestions much > > appreciated. > > > > cheers > > Michael > > > > ------------------------------------------------------------------------- > > This SF.net email is sponsored by: Microsoft > > Defy all challenges. Microsoft(R) Visual Studio 2008. > > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > > _______________________________________________ > > Geotools-devel mailing list > > [email protected] > > https://lists.sourceforge.net/lists/listinfo/geotools-devel > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Microsoft > Defy all challenges. Microsoft(R) Visual Studio 2008. > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > _______________________________________________ > Geotools-devel mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/geotools-devel > > !DSPAM:4045,47b3aa0836438362916074! ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ Geotools-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/geotools-devel
