Before I file a bug I want to make sure I have the problem properly described. Can you please let me know if my analysis is correct? In general I believe the problem is that the sql view code (or gui) isn't properly namespace/workspace aware but at a minimum I have noticed two issues.
1. Deleting a layer ends up deleting the wrong layer, or perhaps multiple. I have had this happen before but attempted to reproduce it and couldn't, but it just happened to me again. I have multiple workspaces with each having layers with the same name based on sql views. My memory is sketchy but I thought the first time this happened it deleted the layer out of both workspaces when I deleted one. This time I deleted one, and went to recreate it (I'm ultimately trying to figure out a different problem) and got this error. A 'links_shifted' sql view is already used in the 'links_shifted' feature type, please choose a different name. I went at looked at the layer list and the links_shifted layer existed in the workspace I had just deleted it from, but was deleted from the other! I don't see any errors in the logs. 2. Perhaps totally unrelated to #1, whenever a sql view based layer is accessed I see the following error in the logs. It appears the code is expecting a real table to exist by this name INFO | jvm 1 | 2011/01/28 12:58:41 | org.postgresql.util.PSQLException: ERROR: relation "public.links_shifted" does not exist INFO | jvm 1 | 2011/01/28 12:58:41 | Where: SQL statement "SELECT has_table_privilege((SELECT usesysid FROM pg_user WHERE usename = session_user), 'public.links_shifted', 'select')" INFO | jvm 1 | 2011/01/28 12:58:41 | at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2062) INFO | jvm 1 | 2011/01/28 12:58:41 | at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1795) INFO | jvm 1 | 2011/01/28 12:58:41 | at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:257) INFO | jvm 1 | 2011/01/28 12:58:41 | at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:479) INFO | jvm 1 | 2011/01/28 12:58:41 | at org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:353) INFO | jvm 1 | 2011/01/28 12:58:41 | at org.postgresql.jdbc2.AbstractJdbc2Statement.executeQuery(AbstractJdbc2Statement.java:252) INFO | jvm 1 | 2011/01/28 12:58:41 | at org.apache.commons.dbcp.DelegatingStatement.executeQuery(DelegatingStatement.java:208) INFO | jvm 1 | 2011/01/28 12:58:41 | at org.apache.commons.dbcp.DelegatingStatement.executeQuery(DelegatingStatement.java:208) INFO | jvm 1 | 2011/01/28 12:58:41 | at org.geotools.data.postgis.PostGISDialect.getOptimizedBounds(PostGISDialect.java:219) INFO | jvm 1 | 2011/01/28 12:58:41 | at org.geotools.jdbc.JDBCDataStore.getBounds(JDBCDataStore.java:1085) INFO | jvm 1 | 2011/01/28 12:58:41 | at org.geotools.jdbc.JDBCFeatureSource.getBoundsInternal(JDBCFeatureSource.java:469) INFO | jvm 1 | 2011/01/28 12:58:41 | at org.geotools.data.store.ContentFeatureSource.getBounds(ContentFeatureSource.java:369) INFO | jvm 1 | 2011/01/28 12:58:41 | at org.geotools.data.store.ContentFeatureCollection.getBounds(ContentFeatureCollection.java:273) INFO | jvm 1 | 2011/01/28 12:58:41 | at org.geotools.gml.producer.FeatureTransformer$FeatureTranslator.encode(FeatureTransformer.java:498) INFO | jvm 1 | 2011/01/28 12:58:41 | at org.geotools.xml.transform.TransformerBase$XMLReaderSupport.parse(TransformerBase.java:714) INFO | jvm 1 | 2011/01/28 12:58:41 | at org.apache.xalan.transformer.TransformerIdentityImpl.transform(TransformerIdentityImpl.java:484) INFO | jvm 1 | 2011/01/28 12:58:41 | at org.geotools.xml.transform.TransformerBase$Task.run(TransformerBase.java:296) INFO | jvm 1 | 2011/01/28 12:58:41 | at org.geotools.xml.transform.TransformerBase.transform(TransformerBase.java:129) INFO | jvm 1 | 2011/01/28 12:58:41 | at org.geotools.xml.transform.TransformerBase.transform(TransformerBase.java:108) INFO | jvm 1 | 2011/01/28 12:58:41 | at org.geoserver.wfs.xml.GML2OutputFormat.encode(GML2OutputFormat.java:275) INFO | jvm 1 | 2011/01/28 12:58:41 | at org.geoserver.wfs.xml.GML2OutputFormat.write(GML2OutputFormat.java:294) INFO | jvm 1 | 2011/01/28 12:58:41 | at org.geoserver.wfs.WFSGetFeatureOutputFormat.write(WFSGetFeatureOutputFormat.java:141) INFO | jvm 1 | 2011/01/28 12:58:41 | at org.geoserver.ows.Dispatcher.response(Dispatcher.java:751) INFO | jvm 1 | 2011/01/28 12:58:41 | at org.geoserver.ows.Dispatcher.handleRequestInternal(Dispatcher.java:233) Please let me know if there is anything else I can do to help narrow down these problems. Thanks, charles p.s. this is on 2.1-RC1 ------------------------------------------------------------------------------ Special Offer-- Download ArcSight Logger for FREE (a $49 USD value)! Finally, a world-class log management solution at an even better price-free! Download using promo code Free_Logger_4_Dev2Dev. Offer expires February 28th, so secure your free ArcSight Logger TODAY! http://p.sf.net/sfu/arcsight-sfd2d _______________________________________________ Geoserver-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/geoserver-users
