Removing a DataStore from the catalog does not call DataAccess.dispose()
------------------------------------------------------------------------

                 Key: GEOS-3066
                 URL: http://jira.codehaus.org/browse/GEOS-3066
             Project: GeoServer
          Issue Type: Bug
          Components: Wicket UI
            Reporter: Gabriel Roldán
            Assignee: Justin Deoliveira
            Priority: Blocker
             Fix For: 2.0-beta1


This one I think is critical since it may leave stale connections.
Basically I don't see DataAccess.dispose() being called from anywhere in the UI 
logic (remove?) nor in the Catalog/ResoucePool. (dispose( DataStoreInfo info ) 
exists in ResoucePool but didn't find a reference to it)

This patch should do the trick imho, but am not so sure:
{code}
### Eclipse Workspace Patch 1.0
#P main
Index: src/main/java/org/geoserver/catalog/ResourcePool.java
===================================================================
--- src/main/java/org/geoserver/catalog/ResourcePool.java       (revision 12454)
+++ src/main/java/org/geoserver/catalog/ResourcePool.java       (working copy)
@@ -300,7 +301,8 @@
      * @param info The data store metadata.
      */
     public void clear( DataStoreInfo info ) {
-        dataStoreCache.remove( info.getName() );
+        dispose(info);
+        dataStoreCache.remove( info.getId() );
     }
     
     /**
{code}

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

------------------------------------------------------------------------------
Register Now for Creativity and Technology (CaT), June 3rd, NYC. CaT
is a gathering of tech-side developers & brand creativity professionals. Meet
the minds behind Google Creative Lab, Visual Complexity, Processing, & 
iPhoneDevCamp asthey present alongside digital heavyweights like Barbarian
Group, R/GA, & Big Spaceship. http://www.creativitycat.com 
_______________________________________________
Geoserver-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geoserver-devel

Reply via email to