geoservercesiumjs

Error in GetCapabilities WMS 1.3.0 geoserver, how to solve?


Error in GetCapabilities WMS 1.3.0 geoserver. Here is an error

enter image description here

This page contains the following errors: error on line 6869 at column 17: XML declaration allowed only at the start of the document Below is a rendering of the page up to the first error.

I want to add data from geoserver to CesiumJs through wms.

Caused by: java.lang.ExceptionInInitializerError: Exception java.lang.IllegalAccessError: superclass access check failed: class org.marlin.pisces.MarlinRenderingEngine (in unnamed module @0x4c04c9c4) cannot access class sun.java2d.pipe.RenderingEngine (in module java.desktop) because module java.desktop does not export sun.java2d.pipe to unnamed module @0x4c04c9c4 [in thread "qtp674483268-24"]
at java.base/java.lang.Class.forName0(Native Method)
at java.base/java.lang.Class.forName(Class.java:375)
at java.desktop/sun.java2d.pipe.RenderingEngine.getInstance(RenderingEngine.java:129)
at java.desktop/sun.java2d.pipe.LoopPipe.<clinit>(LoopPipe.java:49)
at java.desktop/sun.java2d.SurfaceData.<clinit>(SurfaceData.java:450)
at java.desktop/sun.awt.windows.WToolkit.initIDs(Native Method)
at java.desktop/sun.awt.windows.WToolkit.<clinit>(WToolkit.java:195)
at java.desktop/sun.awt.Win32GraphicsEnvironment.<clinit>(Win32GraphicsEnvironment.java:60)
at java.desktop/sun.awt.PlatformGraphicsInfo.createGE(PlatformGraphicsInfo.java:34)
at java.desktop/java.awt.GraphicsEnvironment$LocalGE.createGE(GraphicsEnvironment.java:93)
at java.desktop/java.awt.GraphicsEnvironment$LocalGE.<clinit>(GraphicsEnvironment.java:84)
at java.desktop/java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(GraphicsEnvironment.java:106)
at java.desktop/java.awt.image.BufferedImage.createGraphics(BufferedImage.java:1182)
at org.geoserver.wms.map.ImageUtils.prepareTransparency(ImageUtils.java:162)
at org.geoserver.wms.legendgraphic.BufferedImageLegendGraphicBuilder.renderRules(BufferedImageLegendGraphicBuilder.java:327)
at org.geoserver.wms.legendgraphic.BufferedImageLegendGraphicBuilder.buildLegendGraphic(BufferedImageLegendGraphicBuilder.java:265)
at org.geoserver.wms.legendgraphic.BufferedImageLegendGraphicBuilder.buildLegendGraphic(BufferedImageLegendGraphicBuilder.java:77)
at org.geoserver.wms.legendgraphic.PNGLegendOutputFormat.produceLegendGraphic(PNGLegendOutputFormat.java:41)
at org.geoserver.wms.legendgraphic.PNGLegendOutputFormat.produceLegendGraphic(PNGLegendOutputFormat.java:21)
at org.geoserver.wms.capabilities.LegendSampleImpl.createNewSample(LegendSampleImpl.java:178)
at org.geoserver.wms.capabilities.LegendSampleImpl.getLegendURLSize(LegendSampleImpl.java:156)
at org.geoserver.wms.capabilities.Capabilities_1_3_0_Transformer$Capabilities_1_3_0_Translator.handleLegendURL(Capabilities_1_3_0_Transformer.java:1661)
at org.geoserver.wms.capabilities.Capabilities_1_3_0_Transformer$Capabilities_1_3_0_Translator.handleLayerStyles(Capabilities_1_3_0_Transformer.java:1281)
at org.geoserver.wms.capabilities.Capabilities_1_3_0_Transformer$Capabilities_1_3_0_Translator.handleLayer(Capabilities_1_3_0_Transformer.java:1220)
at org.geoserver.wms.capabilities.Capabilities_1_3_0_Transformer$Capabilities_1_3_0_Translator.handleLayerGroup(Capabilities_1_3_0_Transformer.java:1563)
at org.geoserver.wms.capabilities.Capabilities_1_3_0_Transformer$Capabilities_1_3_0_Translator.handleLayerGroups(Capabilities_1_3_0_Transformer.java:1419)
at org.geoserver.wms.capabilities.Capabilities_1_3_0_Transformer$Capabilities_1_3_0_Translator.handleLayers(Capabilities_1_3_0_Transformer.java:834)
at org.geoserver.wms.capabilities.Capabilities_1_3_0_Transformer$Capabilities_1_3_0_Translator.handleCapability(Capabilities_1_3_0_Transformer.java:626)
at org.geoserver.wms.capabilities.Capabilities_1_3_0_Transformer$Capabilities_1_3_0_Translator.encode(Capabilities_1_3_0_Transformer.java:331)
at org.geotools.xml.transform.TransformerBase$XMLReaderSupport.parse(TransformerBase.java:1054)
at org.apache.xalan.transformer.TransformerIdentityImpl.transform(TransformerIdentityImpl.java:485)
at org.geotools.xml.transform.TransformerBase$Task.run(TransformerBase.java:287)
at org.geotools.xml.transform.TransformerBase.transform(TransformerBase.java:121)
at org.geotools.xml.transform.TransformerBase.transform(TransformerBase.java:103)
at org.geoserver.wms.capabilities.Capabilities_1_3_0_Response.write(Capabilities_1_3_0_Response.java:43)
at org.geoserver.config.CapabilitiesCacheHeadersCallback$RevalidateTagResponse.write(CapabilitiesCacheHeadersCallback.java:138)
at org.geoserver.ows.Dispatcher.response(Dispatcher.java:1018)
at org.geoserver.ows.Dispatcher.handleRequestInternal(Dispatcher.java:272)
... 112 more

Solution

  • The thing is that, when you use Java 17 there is file in webapps/geoserver/WEB-INF/lib called marlin-0.9.3.jar . Full path is webapps/geoserver/WEB-INF/lib called marlin-0.9.3.jar. Delete marlin-0.9.3.jar and your problem will be solved. More information you can find here https://docs.geoserver.org/latest/en/user/production/java.html#running-on-java-17