Geoserver cloud 1.8.12 - Error duplicate key value violates unique constraint "settingsinfo_pkey"

Hi !

I’m using geoserver cloud 1.8.12 .

When updating an existing namespace (apply then save) , the following error got displayed :

PreparedStatementCallback; SQL [INSERT INTO settingsinfo(info) VALUES (to_json(?::json))]; ERROR: duplicate key value violates unique constraint “settingsinfo_pkey” Detail: Key (id)=(SettingsInfoImpl-79f6e188:19307476775:-7ff4) already exists.; nested exception is org.postgresql.util.PSQLException: ERROR: duplicate key value violates unique constraint “settingsinfo_pkey” Detail: Key (id)=(SettingsInfoImpl-79f6e188:19307476775:-7ff4) already exists.

May you help me resolving that issue ?

Have a nice day.

Hi @yvanriou,

Apparently you’ve deployed GeoServer Cloud on kubernetes.

  • Have you followed the pgconfig example from the helm chart repository?
  • Are you doing some scripted catalog import?
  • On which pod are you seeing this error? and can you share the logs, at least the part with the full stack trace?

Hi Gabriel,

Thank you for answering and sorry for the delay .

For a first try , all micro-services of Geoserver cloud 1.8.12 are deployed with a docker compose file on a single virtual machine , with pgconfig profile . So no Kuberneted used .

Nothing scripted , i’m using webui to configure .

I started once more Geoserver cloud with an empty postgres config.
Then I created a namespace named ‘routier’
I updated it , clicked on ‘WFS’ and in button ‘Apply’ .

The following message was displayed :

service with id ‘WFSInfoImpl–2431fa85:19329ff82f3:-8000’ already exists

Here is the complete log :

webui | 2024-11-14 09:27:19.592 WARN 1 — [nio-8080-exec-4] org.geoserver.web.data.workspace : Failed to save workspace
webui |
webui | java.lang.IllegalArgumentException: service with id ‘WFSInfoImpl–2431fa85:19329ff82f3:-8000’ already exists
webui | at org.geoserver.config.plugin.GeoServerImpl.add(GeoServerImpl.java:270)
webui | at org.geoserver.web.data.workspace.WorkspaceEditPage.saveWorkspace(WorkspaceEditPage.java:267)
webui | at org.geoserver.web.data.workspace.WorkspaceEditPage$5.onSubmitInternal(WorkspaceEditPage.java:214)
webui | at org.geoserver.web.GeoserverAjaxSubmitLink.onSubmit(GeoserverAjaxSubmitLink.java:38)
webui | at org.apache.wicket.ajax.markup.html.form.AjaxSubmitLink$1.onSubmit(AjaxSubmitLink.java:111)
webui | at org.apache.wicket.ajax.form.AjaxFormSubmitBehavior$AjaxFormSubmitter.onSubmit(AjaxFormSubmitBehavior.java:218)
webui | at org.apache.wicket.markup.html.form.Form.delegateSubmit(Form.java:1312)
webui | at org.apache.wicket.markup.html.form.Form.process(Form.java:976)
webui | at org.apache.wicket.markup.html.form.Form.onFormSubmitted(Form.java:797)
webui | at org.apache.wicket.ajax.form.AjaxFormSubmitBehavior.onEvent(AjaxFormSubmitBehavior.java:174)
webui | at org.apache.wicket.ajax.AjaxEventBehavior.respond(AjaxEventBehavior.java:155)
webui | at org.apache.wicket.ajax.AbstractDefaultAjaxBehavior.onRequest(AbstractDefaultAjaxBehavior.java:601)
webui | at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(Unknown Source)
webui | at java.base/java.lang.reflect.Method.invoke(Unknown Source)
webui | at org.apache.wicket.RequestListenerInterface.internalInvoke(RequestListenerInterface.java:258)
webui | at org.apache.wicket.RequestListenerInterface.invoke(RequestListenerInterface.java:241)
webui | at org.apache.wicket.core.request.handler.ListenerInterfaceRequestHandler.invokeListener(ListenerInterfaceRequestHandler.java:248)
webui | at org.apache.wicket.core.request.handler.ListenerInterfaceRequestHandler.respond(ListenerInterfaceRequestHandler.java:234)
webui | at org.apache.wicket.request.cycle.RequestCycle$HandlerExecutor.respond(RequestCycle.java:895)
webui | at org.apache.wicket.request.RequestHandlerStack.execute(RequestHandlerStack.java:64)
webui | at org.apache.wicket.request.cycle.RequestCycle.execute(RequestCycle.java:265)
webui | at org.apache.wicket.request.cycle.RequestCycle.processRequest(RequestCycle.java:222)
webui | at org.apache.wicket.request.cycle.RequestCycle.processRequestAndDetach(RequestCycle.java:293)
webui | at org.apache.wicket.protocol.http.WicketFilter.processRequestCycle(WicketFilter.java:261)
webui | at org.apache.wicket.protocol.http.WicketFilter.processRequest(WicketFilter.java:203)
webui | at org.apache.wicket.protocol.http.WicketServlet.doPost(WicketServlet.java:159)
webui | at javax.servlet.http.HttpServlet.service(HttpServlet.java:555)
webui | at javax.servlet.http.HttpServlet.service(HttpServlet.java:623)
webui | at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:209)
webui | at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:153)
webui | at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:51)
webui | at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:178)
webui | at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:153)
webui | at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:337)
webui | at org.geoserver.security.filter.GeoServerCompositeFilter$NestedFilterChain.doFilter(GeoServerCompositeFilter.java:71)
webui | at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:115)
webui | at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:81)
webui | at org.geoserver.security.filter.GeoServerCompositeFilter$NestedFilterChain.doFilter(GeoServerCompositeFilter.java:75)
webui | at org.geoserver.security.filter.GeoServerCompositeFilter.doFilter(GeoServerCompositeFilter.java:92)
webui | at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:346)
webui | at org.geoserver.security.filter.GeoServerCompositeFilter$NestedFilterChain.doFilter(GeoServerCompositeFilter.java:71)
webui | at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:122)
webui | at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:116)
webui | at org.geoserver.security.filter.GeoServerCompositeFilter$NestedFilterChain.doFilter(GeoServerCompositeFilter.java:75)
webui | at org.geoserver.security.filter.GeoServerCompositeFilter.doFilter(GeoServerCompositeFilter.java:92)
webui | at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:346)
webui | at org.geoserver.security.filter.GeoServerAnonymousAuthenticationFilter.doFilter(GeoServerAnonymousAuthenticationFilter.java:53)
webui | at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:346)
webui | at org.geoserver.cloud.security.gateway.sharedauth.GatewaySharedAuthenticationFilter$ServerFilter.doFilter(GatewaySharedAuthenticationFilter.java:192)
webui | at org.geoserver.cloud.security.gateway.sharedauth.GatewaySharedAuthenticationFilter.doFilter(GatewaySharedAuthenticationFilter.java:105)
webui | at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:346)
webui | at org.geoserver.security.filter.GeoServerCompositeFilter$NestedFilterChain.doFilter(GeoServerCompositeFilter.java:71)
webui | at org.springframework.security.web.authentication.www.BasicAuthenticationFilter.doFilterInternal(BasicAuthenticationFilter.java:164)
webui | at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:117)
webui | at org.geoserver.security.filter.GeoServerCompositeFilter$NestedFilterChain.doFilter(GeoServerCompositeFilter.java:75)
webui | at org.geoserver.security.filter.GeoServerCompositeFilter.doFilter(GeoServerCompositeFilter.java:92)
webui | at org.geoserver.security.filter.GeoServerBasicAuthenticationFilter.doFilter(GeoServerBasicAuthenticationFilter.java:81)
webui | at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:346)
webui | at org.geoserver.security.filter.GeoServerCompositeFilter$NestedFilterChain.doFilter(GeoServerCompositeFilter.java:71)
webui | at org.geoserver.security.filter.GeoServerSecurityContextPersistenceFilter$1.doFilterInternal(GeoServerSecurityContextPersistenceFilter.java:72)
webui | at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:117)
webui | at org.geoserver.security.filter.GeoServerCompositeFilter$NestedFilterChain.doFilter(GeoServerCompositeFilter.java:75)
webui | at org.geoserver.security.filter.GeoServerCompositeFilter.doFilter(GeoServerCompositeFilter.java:92)
webui | at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:346)
webui | at org.springframework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:221)
webui | at org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:186)
webui | at org.geoserver.security.GeoServerSecurityFilterChainProxy.doFilter(GeoServerSecurityFilterChainProxy.java:141)
webui | at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:178)
webui | at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:153)
webui | at org.geoserver.cloud.gwc.config.core.GeoWebCacheCoreConfiguration$SetRequestPathInfoFilter.doFilter(GeoWebCacheCoreConfiguration.java:282)
webui | at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:178)
webui | at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:153)
webui | at org.springframework.security.oauth2.client.filter.OAuth2ClientContextFilter.doFilter(OAuth2ClientContextFilter.java:64)
webui | at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:178)
webui | at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:153)
webui | at org.geoserver.filters.HTTPMethodFilter.doFilter(HTTPMethodFilter.java:36)
webui | at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:178)
webui | at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:153)
webui | at org.geoserver.filters.LoggingFilter.doFilter(LoggingFilter.java:194)
webui | at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:178)
webui | at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:153)
webui | at org.geoserver.filters.ThreadLocalsCleanupFilter.doFilter(ThreadLocalsCleanupFilter.java:28)
webui | at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:178)
webui | at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:153)
webui | at org.geoserver.platform.AdvancedDispatchFilter.doFilter(AdvancedDispatchFilter.java:39)
webui | at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:178)
webui | at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:153)
webui | at org.geoserver.filters.SpringDelegatingFilter$Chain.doFilter(SpringDelegatingFilter.java:73)
webui | at org.geoserver.filters.HTTPMethodFilter.doFilter(HTTPMethodFilter.java:36)
webui | at org.geoserver.filters.SpringDelegatingFilter$Chain.doFilter(SpringDelegatingFilter.java:70)
webui | at org.geoserver.filters.LoggingFilter.doFilter(LoggingFilter.java:194)
webui | at org.geoserver.filters.SpringDelegatingFilter$Chain.doFilter(SpringDelegatingFilter.java:70)
webui | at org.geoserver.filters.SpringDelegatingFilter.doFilter(SpringDelegatingFilter.java:43)
webui | at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:178)
webui | at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:153)
webui | at org.geoserver.filters.FlushSafeFilter.doFilter(FlushSafeFilter.java:42)
webui | at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:178)
webui | at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:153)
webui | at org.springframework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:100)
webui | at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:117)
webui | at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:178)
webui | at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:153)
webui | at org.springframework.web.filter.FormContentFilter.doFilterInternal(FormContentFilter.java:93)
webui | at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:117)
webui | at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:178)
webui | at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:153)
webui | at org.springframework.boot.actuate.metrics.web.servlet.WebMvcMetricsFilter.doFilterInternal(WebMvcMetricsFilter.java:96)
webui | at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:117)
webui | at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:178)
webui | at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:153)
webui | at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:201)
webui | at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:117)
webui | at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:178)
webui | at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:153)
webui | at org.springframework.web.filter.ForwardedHeaderFilter.doFilterInternal(ForwardedHeaderFilter.java:156)
webui | at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:117)
webui | at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:178)
webui | at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:153)
webui | at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:168)
webui | at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:90)
webui | at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:481)
webui | at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:130)
webui | at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:93)
webui | at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:74)
webui | at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:342)
webui | at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:390)
webui | at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:63)
webui | at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:928)
webui | at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1794)
webui | at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:52)
webui | at org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1191)
webui | at org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:659)
webui | at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
webui | at java.base/java.lang.Thread.run(Unknown Source)

Thank you for your support.

yvan