Issue Summary
Bamboo application throw the below error while visiting ViewAgent page
"java.lang.NullPointerException: Cannot invoke "com.atlassian.bamboo.logger.ErrorDetails.getAgentIds()" because "errorDetails" is null"
Steps to Reproduce
This issue is not always reproducible.
- Choose an agent that you would like to view
- Visit <BAMBOO_BASE_URL>/admin/agent/viewAgent.action?agentId=<AGENT_ID>
Expected Results
View the agent page without any errors
Actual Results
The below exception is thrown in the xxxxxxx.log file:
2025-08-11 12:22:56,459 ERROR [http-nio-8085-exec-12 url: /admin/agent/viewAgent.action; user: XXX ] [FiveOhOh] 500 Exception was thrown. java.lang.NullPointerException: Cannot invoke "com.atlassian.bamboo.logger.ErrorDetails.getAgentIds()" because "errorDetails" is null at com.atlassian.bamboo.logger.DefaultErrorHandler.lambda$getErrorsByAgentId$0(DefaultErrorHandler.java:169) ~[atlassian-bamboo-core-9.6.15.jar:?] at java.util.stream.ReferencePipeline$2$1.accept(ReferencePipeline.java:178) ~[?:?] at java.util.LinkedList$LLSpliterator.forEachRemaining(LinkedList.java:1242) ~[?:?] at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:509) ~[?:?] at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:499) ~[?:?] at java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:921) ~[?:?] at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234) ~[?:?] at java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:682) ~[?:?] at com.atlassian.bamboo.logger.DefaultErrorHandler.getErrorsByAgentId(DefaultErrorHandler.java:171) ~[atlassian-bamboo-core-9.6.15.jar:?] at com.atlassian.bamboo.logger.DecoratingErrorAccessorImpl.getErrorsByAgentId(DecoratingErrorAccessorImpl.java:48) ~[atlassian-bamboo-core-9.6.15.jar:?] at com.atlassian.bamboo.configuration.agent.ViewAgentAdmin.initializeAllFields(ViewAgentAdmin.java:61) ~[atlassian-bamboo-web-9.6.15.jar:?] at com.atlassian.bamboo.configuration.agent.ViewAgent.input(ViewAgent.java:92) ~[atlassian-bamboo-web-9.6.15.jar:?] at jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:?] at jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77) ~[?:?] at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?] at java.lang.reflect.Method.invoke(Method.java:569) ~[?:?] at ognl.OgnlRuntime.invokeMethodInsideSandbox(OgnlRuntime.java:1266) ~[ognl-3.1.29.jar:?] at ognl.OgnlRuntime.invokeMethod(OgnlRuntime.java:1251) ~[ognl-3.1.29.jar:?] at ognl.OgnlRuntime.callAppropriateMethod(OgnlRuntime.java:1969) ~[ognl-3.1.29.jar:?] at ognl.ObjectMethodAccessor.callMethod(ObjectMethodAccessor.java:68) ~[ognl-3.1.29.jar:?] at com.opensymphony.xwork2.ognl.accessor.XWorkMethodAccessor.callMethodWithDebugInfo(XWorkMethodAccessor.java:98) ~[struts2-core-2.5.33-atlassian-2.jar:2.5.33-atlassian-2]
Workaround
At present, there is no straightforward workaround to address this issue. The only known solution is to restart the Bamboo instance.