Spring Boot Admin Server information
- Version: 3.5.0
- Spring Boot version: 3.5.1
- Configured Security: basic-auth
- Webflux or Servlet application: webflux
Description
When viewing the log tail in the Spring Boot Admin UI, the following error is thrown in the browser console despite the logfile being fetched successfully from the actuator endpoint:
Fetching logfile failed: TypeError: i.data.indexOf is not a function
at logtail.ts:64:60
The error occurs because i.data — which is expected to be a plain string — is instead an object. This causes .indexOf() to fail, as that method is not available on objects.
Affected File
spring-boot-admin-server-ui/src/main/frontend/services/logtail.ts — approximately line 64.
Steps to Reproduce
- Configure a Spring Boot application with structured/JSON logging (e.g. Logstash, logback-json encoder)
- Enable the
logfile actuator endpoint
- Make sure that the logfile contains exactly a single logline in JSON format without a newline at the end.
- Open Spring Boot Admin and navigate to the Logfile tab for the application
- Observe the error in the browser console:
TypeError: i.data.indexOf is not a function
Expected Behavior
The logfile content should be returned and handled as a plain string, and the log tail view should render successfully.
Actual Behavior
Axios converts the response body into a JavaScript object, causing .indexOf() to throw a TypeError, and the log tail view fails to render.
Spring Boot Admin Server information
Description
When viewing the log tail in the Spring Boot Admin UI, the following error is thrown in the browser console despite the logfile being fetched successfully from the actuator endpoint:
The error occurs because
i.data— which is expected to be a plain string — is instead an object. This causes.indexOf()to fail, as that method is not available on objects.Affected File
spring-boot-admin-server-ui/src/main/frontend/services/logtail.ts— approximately line 64.Steps to Reproduce
logfileactuator endpointTypeError: i.data.indexOf is not a functionExpected Behavior
The logfile content should be returned and handled as a plain string, and the log tail view should render successfully.
Actual Behavior
Axios converts the response body into a JavaScript object, causing
.indexOf()to throw aTypeError, and the log tail view fails to render.