Space removal gets failed with 'java.lang.NumberFormatException: For input string: ""' error
Platform Notice: Data Center Only - This article only applies to Atlassian products on the Data Center platform.
Note that this KB was created for the Data Center version of the product. Data Center KBs for non-Data-Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.
*Except Fisheye and Crucible
Summary
Space removal operation fails in the UI as below:

Environment
Confluence Data Center
Diagnosis
The following ERROR appears in the <confluence-home>/
atlassian-confluence.log
:
1
2
3
4
5
6
7
8
9
10
11
12
20X-XX-XX XX:XX:XX,XXX ERROR [Long running task: Space removal long running task] [atlassian.event.internal.AsynchronousAbleEventDispatcher] lambda$null$0 There was an exception thrown trying to dispatch event [com.atlassian.confluence.event.events.content.page.PageRemoveEvent@4f0a9d8b[page=page: Test v.1 (XXXXXXXXX),suppressNotifications=false,timestamp=1724301694630]] from the invoker [com.atlassian.event.internal.ComparableListenerInvoker@5fcf6ab5]
-- referer: https://confluence.example.com/spaces/removespace.action?key=SPACE | traceId: cdbf70a0adb365e1 | userName: XXXXX | action: doremovespace | url: /spaces/doremovespace.action | space: XXXXXXXX
java.lang.RuntimeException: For input string: "". Listener: com.confluence.page.tracking.services.PageEventListener event: com.atlassian.confluence.event.events.content.page.PageRemoveEvent
at com.atlassian.event.internal.SingleParameterMethodListenerInvoker.invoke(SingleParameterMethodListenerInvoker.java:53)
at com.atlassian.confluence.event.ConfluenceListenerHandlersConfiguration$TimedListenerInvoker.invoke(ConfluenceListenerHandlersConfiguration.java:96)
at com.atlassian.event.internal.ComparableListenerInvoker.invoke(ComparableListenerInvoker.java:48)
.....................
Caused by: java.lang.NumberFormatException: For input string: ""
.....................
at com.confluence.page.tracking.services.PageService.updatePageSummary(PageService.java:2295)
[...]
at com.confluence.page.tracking.services.PageEventListener.handlePageRemoveEvent(PageEventListener.java:154)
The stack trace includes classes from the third-party app: com.confluence.page.tracking.services.PageEventListener.handlePageRemoveEvent which is part of Page Views plugin by EliteSoft.
The issue was discovered with version 2.5.0 for Page Views plugin:
1
2
3
4
5
6
7
8
9
10
<plugin>
<key>com.elitesoftsp.confluence.page.tracking.plugins</key>
<name>Page Views</name>
<version>2.5.0</version>
<vendor>EliteSoft</vendor>
<status>ENABLED</status>
<vendor-url>https://elitesoftware.atlassian.net/wiki/spaces/PV/overview</vendor-url>
<framework-version>2</framework-version>
<bundled>User installed</bundled>
</plugin>
Cause
Based on the stack trace, the third-party app's code flow can't handle the 'Page Remove' event properly which results in an java.lang.NumberFormatException
.
Solution
Upgrade Page Views to the most recent version. If that doesn't work, try disabling the plugin and then attempt to remove the Space again.
Was this helpful?