Thanks Nuno. That is next on the list after we get through migrating our existing services.
Michael From: Nuno Oliveira <nuno.olive...@geosolutionsgroup.com> Sent: Tuesday, 30 November 2021 3:00 AM To: Michael Sexton <michael.sex...@ga.gov.au> Cc: geoserver-users@lists.sourceforge.net Subject: Re: [Geoserver-users] App-schema services with jdbcMultipleValue attribute mappings throw exception for GetFeatureInfo request [SEC=UNOFFICIAL] Great that you found a solution, in the future, you may want o to have a look at the GeoServer Features Templating plugin<https://docs.geoserver.org/master/en/user/community/features-templating/index.html>, it avoids that type of situation by decoupling features building, querying, and output representation. On Wed, Nov 24, 2021 at 5:08 AM Michael Sexton <michael.sex...@ga.gov.au<mailto:michael.sex...@ga.gov.au>> wrote: Resolved this problem using a solution posted to the mailing list by Kathi Schleidt Re: [Geoserver-users] App Schema jdbcMultipleValue without targetValue - null error (mail-archive.com)<https://www.mail-archive.com/geoserver-users@lists.sourceforge.net/msg33199.html> Which itself was work done by Jorge Samuel Mendes de Jesus. The jdbcMultipleValue still has problems but this is a nice alternative solution. From: Michael Sexton <michael.sex...@ga.gov.au<mailto:michael.sex...@ga.gov.au>> Sent: Monday, 22 November 2021 10:05 AM To: 'geoserver-users@lists.sourceforge.net<mailto:geoserver-users@lists.sourceforge.net>' <geoserver-users@lists.sourceforge.net<mailto:geoserver-users@lists.sourceforge.net>> Subject: [Geoserver-users] App-schema services with jdbcMultipleValue attribute mappings throw exception for GetFeatureInfo request [SEC=UNOFFICIAL] Hi all GeoServer version: 2.19.2 Database type: Oracle When clicking a point on a WMS that delivers a complex feature data standard, if the app-schema mapping file contains a jdbcMultipleValue mapping, the application throws an exception. The GetFeatureInfo request: http://localhost:8080/er/wms?SERVICE=WMS&VERSION=1.1.1&REQUEST=GetFeatureInfo&FORMAT=image%2Fpng&TRANSPARENT=true&QUERY_LAYERS=er%3AMineralOccurrence&STYLES&LAYERS=er%3AMineralOccurrence&exceptions=application%2Fvnd.ogc.se_inimage&INFO_FORMAT=text%2Fhtml&FEATURE_COUNT=50&X=50&Y=50&SRS=EPSG%3A4283&WIDTH=101&HEIGHT=101&BBOX=116.85058593750001%2C-32.6953125%2C125.72753906250001%2C-23.818359375 The exception: 2021-11-22 09:55:05,661 ERROR [org.geoserver.ows] - org.geoserver.platform.ServiceException: Failed to run GetFeatureInfo on layer er:MineralOccurrence at org.geoserver.wms.GetFeatureInfo.execute(GetFeatureInfo.java:87) at org.geoserver.wms.GetFeatureInfo.run(GetFeatureInfo.java:38) at org.geoserver.wms.DefaultWebMapService.getFeatureInfo(DefaultWebMapService.java:260) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:343) at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:198) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163) at org.geoserver.kml.WebMapServiceKmlInterceptor.invoke(WebMapServiceKmlInterceptor.java:38) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186) at org.geoserver.ows.util.RequestObjectLogger.invoke(RequestObjectLogger.java:50) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186) at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:212) at com.sun.proxy.$Proxy114.getFeatureInfo(Unknown Source) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.geoserver.ows.Dispatcher.execute(Dispatcher.java:876) at org.geoserver.ows.Dispatcher.handleRequestInternal(Dispatcher.java:265) at org.springframework.web.servlet.mvc.AbstractController.handleRequest(AbstractController.java:177) at org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:52) at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:1040) at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:943) at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:1006) at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:898) at javax.servlet.http.HttpServlet.service(HttpServlet.java:634) at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:883) at javax.servlet.http.HttpServlet.service(HttpServlet.java:741) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at org.geoserver.filters.ThreadLocalsCleanupFilter.doFilter(ThreadLocalsCleanupFilter.java:26) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at org.geoserver.filters.SpringDelegatingFilter$Chain.doFilter(SpringDelegatingFilter.java:69) at org.geoserver.wms.animate.AnimatorFilter.doFilter(AnimatorFilter.java:70) at org.geoserver.filters.SpringDelegatingFilter$Chain.doFilter(SpringDelegatingFilter.java:66) at org.geoserver.filters.SpringDelegatingFilter.doFilter(SpringDelegatingFilter.java:41) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at org.geoserver.platform.AdvancedDispatchFilter.doFilter(AdvancedDispatchFilter.java:37) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:201) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:119) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:320) at org.geoserver.security.filter.GeoServerCompositeFilter$NestedFilterChain.doFilter(GeoServerCompositeFilter.java:70) at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:127) at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:91) at org.geoserver.security.filter.GeoServerCompositeFilter$NestedFilterChain.doFilter(GeoServerCompositeFilter.java:74) at org.geoserver.security.filter.GeoServerCompositeFilter.doFilter(GeoServerCompositeFilter.java:91) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) at org.geoserver.security.filter.GeoServerCompositeFilter$NestedFilterChain.doFilter(GeoServerCompositeFilter.java:70) at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:119) at org.geoserver.security.filter.GeoServerCompositeFilter$NestedFilterChain.doFilter(GeoServerCompositeFilter.java:74) at org.geoserver.security.filter.GeoServerCompositeFilter.doFilter(GeoServerCompositeFilter.java:91) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) at org.geoserver.security.filter.GeoServerAnonymousAuthenticationFilter.doFilter(GeoServerAnonymousAuthenticationFilter.java:51) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) at org.geoserver.security.filter.GeoServerCompositeFilter$NestedFilterChain.doFilter(GeoServerCompositeFilter.java:70) at org.springframework.security.web.authentication.www.BasicAuthenticationFilter.doFilterInternal(BasicAuthenticationFilter.java:158) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:119) at org.geoserver.security.filter.GeoServerCompositeFilter$NestedFilterChain.doFilter(GeoServerCompositeFilter.java:74) at org.geoserver.security.filter.GeoServerCompositeFilter.doFilter(GeoServerCompositeFilter.java:91) at org.geoserver.security.filter.GeoServerBasicAuthenticationFilter.doFilter(GeoServerBasicAuthenticationFilter.java:81) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) at org.geoserver.security.filter.GeoServerCompositeFilter$NestedFilterChain.doFilter(GeoServerCompositeFilter.java:70) at org.springframework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:105) at org.geoserver.security.filter.GeoServerSecurityContextPersistenceFilter$1.doFilter(GeoServerSecurityContextPersistenceFilter.java:52) at org.geoserver.security.filter.GeoServerCompositeFilter$NestedFilterChain.doFilter(GeoServerCompositeFilter.java:74) at org.geoserver.security.filter.GeoServerCompositeFilter.doFilter(GeoServerCompositeFilter.java:91) at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) at org.springframework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:215) at org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:178) at org.geoserver.security.GeoServerSecurityFilterChainProxy.doFilter(GeoServerSecurityFilterChainProxy.java:142) at org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:358) at org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:271) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at org.geoserver.filters.LoggingFilter.doFilter(LoggingFilter.java:101) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at org.geoserver.filters.GZIPFilter.doFilter(GZIPFilter.java:47) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at org.geoserver.filters.SessionDebugFilter.doFilter(SessionDebugFilter.java:46) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at org.apache.catalina.filters.CorsFilter.handleNonCORS(CorsFilter.java:352) at org.apache.catalina.filters.CorsFilter.doFilter(CorsFilter.java:171) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:202) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:490) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:139) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92) at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:678) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:74) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343) at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:408) at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66) at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:853) at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1587) at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) at java.lang.Thread.run(Thread.java:748) Caused by: java.lang.RuntimeException: java.lang.RuntimeException: Error applying mapping with targetAttribute er:form at org.geotools.data.complex.AbstractMappingFeatureIterator.next(AbstractMappingFeatureIterator.java:421) at org.geoserver.wms.featureinfo.FeatureCollectionDecorator.size(FeatureCollectionDecorator.java:111) at org.geoserver.wms.GetFeatureInfo.addToResults(GetFeatureInfo.java:126) at org.geoserver.wms.GetFeatureInfo.execute(GetFeatureInfo.java:77) ... 115 more Caused by: java.lang.RuntimeException: Error applying mapping with targetAttribute er:form at org.geotools.data.complex.DataAccessMappingFeatureIterator.computeNext(DataAccessMappingFeatureIterator.java:1488) at org.geotools.data.complex.AbstractMappingFeatureIterator.next(AbstractMappingFeatureIterator.java:418) ... 118 more Caused by: java.io.IOException at org.geotools.appschema.jdbc.JoiningJDBCFeatureSource.getJoiningReaderInternal(JoiningJDBCFeatureSource.java:1373) at org.geotools.data.complex.DataAccessMappingFeatureIterator.extractMultipleValues(DataAccessMappingFeatureIterator.java:988) at org.geotools.data.complex.DataAccessMappingFeatureIterator.setAttributeValue(DataAccessMappingFeatureIterator.java:649) at org.geotools.data.complex.DataAccessMappingFeatureIterator.computeNext(DataAccessMappingFeatureIterator.java:1437) ... 119 more Caused by: java.lang.RuntimeException: Subclasses must implement this method in order to handle geometries at org.geotools.data.jdbc.FilterToSQL.visitLiteralGeometry(FilterToSQL.java:1724) at org.geotools.data.jdbc.FilterToSQL.visit(FilterToSQL.java:1601) at org.geotools.jdbc.PreparedFilterToSQL.visit(PreparedFilterToSQL.java:80) at org.geotools.filter.LiteralExpressionImpl.accept(LiteralExpressionImpl.java:242) at org.geotools.data.oracle.OracleFilterToSQL.doSDORelate(OracleFilterToSQL.java:514) at org.geotools.data.oracle.OracleFilterToSQL.visitBinarySpatialOperator(OracleFilterToSQL.java:415) at org.geotools.data.oracle.OracleFilterToSQL.visitBinarySpatialOperator(OracleFilterToSQL.java:390) at org.geotools.data.jdbc.FilterToSQL.visitBinarySpatialOperator(FilterToSQL.java:1262) at org.geotools.data.jdbc.FilterToSQL.visit(FilterToSQL.java:1206) at org.geotools.filter.spatial.IntersectsImpl.accept(IntersectsImpl.java:56) at org.geotools.data.jdbc.FilterToSQL.encode(FilterToSQL.java:282) at org.geotools.data.jdbc.FilterToSQL.encodeToString(FilterToSQL.java:308) at org.geotools.appschema.jdbc.JoiningJDBCFeatureSource.processSortByKey(JoiningJDBCFeatureSource.java:927) at org.geotools.appschema.jdbc.JoiningJDBCFeatureSource.buildFiterBasedOnSortBy(JoiningJDBCFeatureSource.java:850) at org.geotools.appschema.jdbc.JoiningJDBCFeatureSource.buildFilter(JoiningJDBCFeatureSource.java:782) at org.geotools.appschema.jdbc.JoiningJDBCFeatureSource.selectSQL(JoiningJDBCFeatureSource.java:641) at org.geotools.appschema.jdbc.JoiningJDBCFeatureSource.selectSQL(JoiningJDBCFeatureSource.java:388) at org.geotools.appschema.jdbc.JoiningJDBCFeatureSource.getJoiningReaderInternal(JoiningJDBCFeatureSource.java:1321) ... 122 more The mapping <AttributeMapping> <targetAttribute>er:form</targetAttribute> <jdbcMultipleValue> <sourceColumn>ENO</sourceColumn> <targetTable>OZMIN_ER_MINOCC_FORMS</targetTable> <targetColumn>ENO</targetColumn> </jdbcMultipleValue> <ClientProperty> <name>xlink:href</name> <value>FORM_HREF</value> </ClientProperty> <ClientProperty> <name>xlink:title</name> <value>FORM_TITLE</value> </ClientProperty> </AttributeMapping> I tested it by removing the mapping, which avoids the exception. Thanks Michael Sexton Data Analyst | MEGIS Minerals Energy Groundwater | GEOSCIENCE AUSTRALIA ____________________________________________________________ Phone: +61 2 6249 9262 Fax: +61 2 6249 9999 Email: michael.sex...@ga.gov.au<mailto:michael.sex...@ga.gov.au> Web: www.ga.gov.au<http://www.ga.gov.au/> Cnr Jerrabomberra Avenue and Hindmarsh Drive Symonston ACT 2609 GPO Box 378 Canberra ACT 2601 Australia Applying geoscience to Australia’s most important challenges Geoscience Australia Disclaimer: This e-mail (and files transmitted with it) is intended only for the person or entity to which it is addressed. If you are not the intended recipient, then you have received this e-mail by mistake and any use, dissemination, forwarding, printing or copying of this e-mail and its file attachments is prohibited. The security of emails transmitted cannot be guaranteed; by forwarding or replying to this email, you acknowledge and accept these risks. Geoscience Australia Disclaimer: This e-mail (and files transmitted with it) is intended only for the person or entity to which it is addressed. If you are not the intended recipient, then you have received this e-mail by mistake and any use, dissemination, forwarding, printing or copying of this e-mail and its file attachments is prohibited. The security of emails transmitted cannot be guaranteed; by forwarding or replying to this email, you acknowledge and accept these risks. _______________________________________________ Geoserver-users mailing list Please make sure you read the following two resources before posting to this list: - Earning your support instead of buying it, but Ian Turton: http://www.ianturton.com/talks/foss4g.html#/ - The GeoServer user list posting guidelines: http://geoserver.org/comm/userlist-guidelines.html If you want to request a feature or an improvement, also see this: https://github.com/geoserver/geoserver/wiki/Successfully-requesting-and-integrating-new-features-and-improvements-in-GeoServer Geoserver-users@lists.sourceforge.net<mailto:Geoserver-users@lists.sourceforge.net> https://lists.sourceforge.net/lists/listinfo/geoserver-users -- Regards, Nuno Oliveira == GeoServer Professional Services from the experts! Visit http://bit.ly/gs-services-us for more information. == Nuno Miguel Carvalho Oliveira @nmcoliveira Technical Lead / Project Manager GeoSolutions Group phone: +39 0584 962313 fax: +39 0584 1660272 https://www.geosolutionsgroup.com/ http://twitter.com/geosolutions_it ------------------------------------------------------- Con riferimento alla normativa sul trattamento dei dati personali (Reg. UE 2016/679 - Regolamento generale sulla protezione dei dati “GDPR”), si precisa che ogni circostanza inerente alla presente email (il suo contenuto, gli eventuali allegati, etc.) è un dato la cui conoscenza è riservata al/i solo/i destinatario/i indicati dallo scrivente. Se il messaggio Le è giunto per errore, è tenuta/o a cancellarlo, ogni altra operazione è illecita. Le sarei comunque grato se potesse darmene notizia. This email is intended only for the person or entity to which it is addressed and may contain information that is privileged, confidential or otherwise protected from disclosure. We remind that - as provided by European Regulation 2016/679 “GDPR” - copying, dissemination or use of this e-mail or the information herein by anyone other than the intended recipient is prohibited. If you have received this email by mistake, please notify us immediately by telephone or e-mail. Geoscience Australia Disclaimer: This e-mail (and files transmitted with it) is intended only for the person or entity to which it is addressed. If you are not the intended recipient, then you have received this e-mail by mistake and any use, dissemination, forwarding, printing or copying of this e-mail and its file attachments is prohibited. The security of emails transmitted cannot be guaranteed; by forwarding or replying to this email, you acknowledge and accept these risks.
_______________________________________________ Geoserver-users mailing list Please make sure you read the following two resources before posting to this list: - Earning your support instead of buying it, but Ian Turton: http://www.ianturton.com/talks/foss4g.html#/ - The GeoServer user list posting guidelines: http://geoserver.org/comm/userlist-guidelines.html If you want to request a feature or an improvement, also see this: https://github.com/geoserver/geoserver/wiki/Successfully-requesting-and-integrating-new-features-and-improvements-in-GeoServer Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users