Closed GoogleCodeExporter closed 8 years ago
Thinking about this more, it may make sense to add a destroy method not on
JavaScriptDB but on the abstract methods further up the hierarchy chain. The
idea
being that implementers may have a desire to implement this (vs the static
method
proposal on JavaScriptDB). Though I'm not sure how PersvereFilter would get a
reference to the data store to call the release.
Original comment by kevin.ha...@gmail.com
on 13 May 2009 at 10:44
Attached are patch files to fix this. Basically, I implemented the destroy
method for when the servlet is taken out
of service. It calls the DataSourceManager.destroy to iterate over the data
sources. Data sources that implement
the DestroyAwareDataSource destroy() method are called. JavaScriptDBSource now
implements
DestoryAwareDataSoruce and calls into JavaScriptDB to close() the files that it
uses which in turn releases the
locks.
I've tested this on Tomcat via the free WebSphere Community Edition app server
which uses Tomcat as the web
container engine.
Original comment by kevin.ha...@gmail.com
on 15 May 2009 at 3:46
Attachments:
Great patch, looks good.
Original comment by kris...@gmail.com
on 21 May 2009 at 8:55
Original issue reported on code.google.com by
kevin.ha...@gmail.com
on 13 May 2009 at 8:58