Over-trimmed that stack trace. Below is another one.
Hypothesis: the key bit turns out to be
at org.jasig.portal.layout.TransientUserLayoutManagerWrapper.getSubscribeId(TransientUserLayoutManagerWrapper.java:343) ~[classes/:na]
This is a request for a resource URL of a portlet by fname. The TransientUserLayoutManagerWrapper tries to check whether there's an existing subscribeId for that portlet in the layout and prefers to use that, falling back on instantiating a temporary portlet window only if it doesn't find one.
MyUW is calling that more and more concurrently, with widgets and notifications on the home page making callbacks for JSON and content out of resource URLs out of portlets addressed by fname.
So my working hypothesis is that DLM isn't threadsafe when accessed in this way, which was probably just fine in the olden days of rendering one portlet by fname at a time maximized, but is problematic when the browser concurrently requests a bunch of resource URLs addressing portlets by fname.
Here's an idea, though: aside from the bookmarks portlet, I don't think we're using *user-edited* portlet preferences in MyUW. We're using lots of portlet-preferences, but we're using them as if they were portlet-definition parameters, not something users can edit on a per-portlet-subscription basis.
So long as that's the case, there's no need for TransientUserLayoutManagerWrapper to be asking the underlying DLM whether these fnames are in the layout, so I can hack the wrapper to greatly reduce the concurrent requests down into DLM.
May try that to try to get these stack traces to stop happening before there's too much chance for DLM layout corruption or whatever bad thing happens from concurrent DLM requests of this kind...
ERROR [ajp-nio-8009-exec-30] o.j.p.web.ExceptionLoggingFilter 2019-10-17 14:34:00,509 - uPortal: unhandled exception 'NOT_FOUND_ERR: An attempt is made to reference a node in a context where it does not exist.' for URL=/portal/p/earnings-statement/max/listOfLinks.resource.uP, user=dREDACTEDg , from IP=1REDACTED1
org.w3c.dom.DOMException: NOT_FOUND_ERR: An attempt is made to reference a node in a context where it does not exist.
at com.sun.org.apache.xerces.internal.dom.ParentNode.internalRemoveChild(ParentNode.java:504) ~[na:1.8.0_222]
at com.sun.org.apache.xerces.internal.dom.ParentNode.removeChild(ParentNode.java:484) ~[na:1.8.0_222]
at org.jasig.portal.layout.dlm.DeleteManager.applyAndUpdateDeleteSet(DeleteManager.java:93) ~[classes/:na]
at org.jasig.portal.layout.dlm.PLFIntegrator.mergePLFintoILF(PLFIntegrator.java:51) ~[classes/:na]
at org.jasig.portal.layout.dlm.RDBMDistributedLayoutStore.getCompositeLayout(RDBMDistributedLayoutStore.java:1352) ~[classes/:na]
at org.jasig.portal.layout.dlm.RDBMDistributedLayoutStore._getUserLayout(RDBMDistributedLayoutStore.java:1183) ~[classes/:na]
at org.jasig.portal.layout.dlm.RDBMDistributedLayoutStore.getUserLayout(RDBMDistributedLayoutStore.java:374) ~[classes/:na]
at sun.reflect.GeneratedMethodAccessor516.invoke(Unknown Source) ~[na:na]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_222]
at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_222]
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:317) ~[spring-aop-3.2.9.RELEASE.jar:3.2.9.RELEASE]
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:198) ~[spring-aop-3.2.9.RELEASE.jar:3.2.9.RELEASE]
at com.sun.proxy.$Proxy510.getUserLayout(Unknown Source) ~[na:na]
at org.jasig.portal.layout.dlm.DistributedLayoutManager.getDistributedUserLayout(DistributedLayoutManager.java:230) ~[classes/:na]
at org.jasig.portal.layout.dlm.DistributedLayoutManager.getUserLayoutDOM(DistributedLayoutManager.java:217) ~[classes/:na]
at org.jasig.portal.layout.dlm.DistributedLayoutManager.getSubscribeId(DistributedLayoutManager.java:1316) ~[classes/:na]
at org.jasig.portal.layout.TransientUserLayoutManagerWrapper.getSubscribeId(TransientUserLayoutManagerWrapper.java:343) ~[classes/:na]
at org.jasig.portal.portlet.registry.PortletEntityRegistryImpl.getOrCreatePortletEntityByFname(PortletEntityRegistryImpl.java:253) ~[classes/:na]
at org.jasig.portal.portlet.registry.PortletWindowRegistryImpl.getOrCreateDefaultPortletWindowByFname(PortletWindowRegistryImpl.java:166) ~[classes/:na]
at sun.reflect.GeneratedMethodAccessor433.invoke(Unknown Source) ~[na:na]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_222]
at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_222]
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:317) ~[spring-aop-3.2.9.RELEASE.jar:3.2.9.RELEASE]
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:183) ~[spring-aop-3.2.9.RELEASE.jar:3.2.9.RELEASE]
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:150) ~[spring-aop-3.2.9.RELEASE.jar:3.2.9.RELEASE]
at org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:91) ~[spring-aop-3.2.9.RELEASE.jar:3.2.9.RELEASE]
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172) ~[spring-aop-3.2.9.RELEASE.jar:3.2.9.RELEASE]
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204) ~[spring-aop-3.2.9.RELEASE.jar:3.2.9.RELEASE]
at com.sun.proxy.$Proxy483.getOrCreateDefaultPortletWindowByFname(Unknown Source) ~[na:na]
at org.jasig.portal.url.SingleTabUrlNodeSyntaxHelper.getPortletForFolderName(SingleTabUrlNodeSyntaxHelper.java:384) ~[classes/:na]
at sun.reflect.GeneratedMethodAccessor413.invoke(Unknown Source) ~[na:na]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_222]
at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_222]
As ever,
Andrew