Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Collection in broken state! Requesting VC results in "Internal error" #189

Open
twagoo opened this issue May 3, 2022 · 2 comments
Open
Labels

Comments

@twagoo
Copy link
Member

twagoo commented May 3, 2022

This appears to have been introduced after finding an (apparent) duplicate link in a published collection. The duplicate link wasn't added manually, so that could have been a glitch as well. After removing one of the duplicate link entries pair and saving the collection, it could no longer be requested.

All of these now return an HTML page with 'Internal error' content:

In the final case, a stacktrace is included:

<!doctype html>
<html lang="en"><head><title>HTTP Status 500 – Internal Server Error</title><style type="text/css">body {font-family:Tahoma,Arial,sans-serif;} h1, h2, h3, b {color:white;background-color:#525D76;} h1 {font-size:22px;} h2 {font-size:16px;} h3 {font-size:14px;} p {font-size:12px;} a {color:black;} .line {height:1px;background-color:#525D76;border:none;}</style></head>
<body>
<h1>HTTP Status 500 – Internal Server Error</h1>
<hr class="line" /><p><b>Type</b> Exception Report</p><p><b>Message</b> java.lang.NullPointerException</p><p><b>Description</b> The server encountered an unexpected condition that prevented it from fulfilling the request.</p><p><b>Exception</b></p>
<pre>javax.servlet.ServletException: java.lang.NullPointerException
	org.glassfish.jersey.servlet.WebComponent.serviceImpl(WebComponent.java:410)
	org.glassfish.jersey.servlet.WebComponent.service(WebComponent.java:346)
	org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:366)
	org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:319)
	org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:205)
	org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
	eu.clarin.cmdi.virtualcollectionregistry.VcrWicketFilter.doFilter(VcrWicketFilter.java:43)
	org.apache.catalina.filters.CorsFilter.handleNonCORS(CorsFilter.java:368)
	org.apache.catalina.filters.CorsFilter.doFilter(CorsFilter.java:174)
	eu.clarin.cmdi.virtualcollectionregistry.gui.CharacterEncodingFilter.doFilter(CharacterEncodingFilter.java:34)
	eu.clarin.cmdi.virtualcollectionregistry.rest.PersistenceFilter.doFilter(PersistenceFilter.java:34)
	de.mpg.aai.shhaa.AuthFilter.doFilter(AuthFilter.java:96)
</pre><p><b>Root Cause</b></p><pre>java.lang.NullPointerException
	eu.clarin.cmdi.virtualcollectionregistry.service.impl.VirtualCollectionCMDICreatorImpl.createResources(VirtualCollectionCMDICreatorImpl.java:132)
	eu.clarin.cmdi.virtualcollectionregistry.service.impl.VirtualCollectionCMDICreatorImpl.createMetadataStructure(VirtualCollectionCMDICreatorImpl.java:92)
	eu.clarin.cmdi.virtualcollectionregistry.service.impl.VirtualCollectionCMDIWriterImpl.writeCMDI(VirtualCollectionCMDIWriterImpl.java:62)
	eu.clarin.cmdi.virtualcollectionregistry.service.impl.VirtualCollectionMarshallerImpl.marshalAsCMDI(VirtualCollectionMarshallerImpl.java:194)
	eu.clarin.cmdi.virtualcollectionregistry.rest.VirtualCollectionCMDIBodyWriter.writeTo(VirtualCollectionCMDIBodyWriter.java:47)
	eu.clarin.cmdi.virtualcollectionregistry.rest.VirtualCollectionCMDIBodyWriter.writeTo(VirtualCollectionCMDIBodyWriter.java:25)
	org.glassfish.jersey.message.internal.WriterInterceptorExecutor$TerminalWriterInterceptor.invokeWriteTo(WriterInterceptorExecutor.java:242)
	org.glassfish.jersey.message.internal.WriterInterceptorExecutor$TerminalWriterInterceptor.aroundWriteTo(WriterInterceptorExecutor.java:227)
	org.glassfish.jersey.message.internal.WriterInterceptorExecutor.proceed(WriterInterceptorExecutor.java:139)
	org.glassfish.jersey.server.internal.JsonWithPaddingInterceptor.aroundWriteTo(JsonWithPaddingInterceptor.java:85)
	org.glassfish.jersey.message.internal.WriterInterceptorExecutor.proceed(WriterInterceptorExecutor.java:139)
	org.glassfish.jersey.server.internal.MappableExceptionWrapperInterceptor.aroundWriteTo(MappableExceptionWrapperInterceptor.java:61)
	org.glassfish.jersey.message.internal.WriterInterceptorExecutor.proceed(WriterInterceptorExecutor.java:139)
	org.glassfish.jersey.message.internal.MessageBodyFactory.writeTo(MessageBodyFactory.java:1116)
	org.glassfish.jersey.server.ServerRuntime$Responder.writeResponse(ServerRuntime.java:638)
	org.glassfish.jersey.server.ServerRuntime$Responder.processResponse(ServerRuntime.java:371)
	org.glassfish.jersey.server.ServerRuntime$Responder.process(ServerRuntime.java:361)
	org.glassfish.jersey.server.ServerRuntime$1.run(ServerRuntime.java:256)
	org.glassfish.jersey.internal.Errors$1.call(Errors.java:248)
	org.glassfish.jersey.internal.Errors$1.call(Errors.java:244)
	org.glassfish.jersey.internal.Errors.process(Errors.java:292)
	org.glassfish.jersey.internal.Errors.process(Errors.java:274)
	org.glassfish.jersey.internal.Errors.process(Errors.java:244)
	org.glassfish.jersey.process.internal.RequestScope.runInScope(RequestScope.java:265)
	org.glassfish.jersey.server.ServerRuntime.process(ServerRuntime.java:232)
	org.glassfish.jersey.server.ApplicationHandler.handle(ApplicationHandler.java:680)
	org.glassfish.jersey.servlet.WebComponent.serviceImpl(WebComponent.java:394)
	org.glassfish.jersey.servlet.WebComponent.service(WebComponent.java:346)
	org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:366)
	org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:319)
	org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:205)
	org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
	eu.clarin.cmdi.virtualcollectionregistry.VcrWicketFilter.doFilter(VcrWicketFilter.java:43)
	org.apache.catalina.filters.CorsFilter.handleNonCORS(CorsFilter.java:368)
	org.apache.catalina.filters.CorsFilter.doFilter(CorsFilter.java:174)
	eu.clarin.cmdi.virtualcollectionregistry.gui.CharacterEncodingFilter.doFilter(CharacterEncodingFilter.java:34)
	eu.clarin.cmdi.virtualcollectionregistry.rest.PersistenceFilter.doFilter(PersistenceFilter.java:34)
	de.mpg.aai.shhaa.AuthFilter.doFilter(AuthFilter.java:96)
</pre>
<p><b>Note</b> The full stack trace of the root cause is available in the server logs.</p><hr class="line" /><h3>Apache Tomcat/8.5.70</h3>
</body>
</html>%
@twagoo twagoo added the bug label May 3, 2022
@WillemElbers
Copy link
Contributor

WillemElbers commented May 9, 2022

Server side exception when trying to access the details page:

...
	at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:78) ~[catalina.jar:8.5.70]
	at org.apache.catalina.valves.RemoteIpValve.invoke(RemoteIpValve.java:769) ~[catalina.jar:8.5.70]
	at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:364) ~[catalina.jar:8.5.70]
	at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:624) ~[tomcat-coyote.jar:8.5.70]
	at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:65) ~[tomcat-coyote.jar:8.5.70]
	at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:831) ~[tomcat-coyote.jar:8.5.70]
	at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1650) ~[tomcat-coyote.jar:8.5.70]
	at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49) ~[tomcat-coyote.jar:8.5.70]
	at org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1191) ~[tomcat-util.jar:8.5.70]
	at org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:659) ~[tomcat-util.jar:8.5.70]
	at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) ~[tomcat-util.jar:8.5.70]
	at java.lang.Thread.run(Thread.java:834) ~[?:?]
Caused by: java.lang.NullPointerException
	at eu.clarin.cmdi.virtualcollectionregistry.gui.pages.ReferenceLinkPanel.<init>(ReferenceLinkPanel.java:47) ~[classes/:?]
	at eu.clarin.cmdi.virtualcollectionregistry.gui.pages.VirtualCollectionDetailsPage$3.populateItem(VirtualCollectionDetailsPage.java:426) ~[classes/:?]
	at org.apache.wicket.extensions.markup.html.repeater.data.grid.AbstractDataGridView.populateItem(AbstractDataGridView.java:156) ~[wicket-extensions-7.12.0.jar:7.12.0]
	at org.apache.wicket.markup.repeater.RefreshingView$1.newItem(RefreshingView.java:114) ~[wicket-core-7.12.0.jar:7.12.0]
	at org.apache.wicket.markup.repeater.DefaultItemReuseStrategy$1.next(DefaultItemReuseStrategy.java:75) ~[wicket-core-7.12.0.jar:7.12.0]
	at org.apache.wicket.markup.repeater.DefaultItemReuseStrategy$1.next(DefaultItemReuseStrategy.java:56) ~[wicket-core-7.12.0.jar:7.12.0]
	at org.apache.wicket.markup.repeater.RefreshingView.addItems(RefreshingView.java:189) ~[wicket-core-7.12.0.jar:7.12.0]
	at org.apache.wicket.markup.repeater.RefreshingView.onPopulate(RefreshingView.java:97) ~[wicket-core-7.12.0.jar:7.12.0]
	at org.apache.wicket.markup.repeater.AbstractRepeater.onBeforeRender(AbstractRepeater.java:124) ~[wicket-core-7.12.0.jar:7.12.0]
	at org.apache.wicket.markup.repeater.AbstractPageableView.onBeforeRender(AbstractPageableView.java:115) ~[wicket-core-7.12.0.jar:7.12.0]
	at org.apache.wicket.Component.internalBeforeRender(Component.java:950) ~[wicket-core-7.12.0.jar:7.12.0]
	at org.apache.wicket.Component.beforeRender(Component.java:1018) ~[wicket-core-7.12.0.jar:7.12.0]
	at org.apache.wicket.MarkupContainer.onBeforeRenderChildren(MarkupContainer.java:1826) ~[wicket-core-7.12.0.jar:7.12.0]

@WillemElbers
Copy link
Contributor

Set collection to private state for now

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants