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

spring boot 1.x mapping result handle(in UI) maybe wrong? #2122

Closed
lagudomeze opened this issue Sep 18, 2022 · 2 comments
Closed

spring boot 1.x mapping result handle(in UI) maybe wrong? #2122

lagudomeze opened this issue Sep 18, 2022 · 2 comments

Comments

@lagudomeze
Copy link

frontend mappings index.vue: isOldMetrics is true only if contentType equals "vnd.spring-boot.actuator.v2"

if (res.headers['content-type'].includes('application/vnd.spring-boot.actuator.v2')) {
this.contexts = res.data.contexts;
} else {
this.isOldMetrics = true;
}

but with legacy convert to last spring boot api version

private static ClientResponse convertLegacyResponse(LegacyEndpointConverter converter, ClientResponse response) {
return response.mutate().headers((headers) -> {
headers.replace(HttpHeaders.CONTENT_TYPE,
singletonList(ApiVersion.LATEST.getProducedMimeType().toString()));
headers.remove(HttpHeaders.CONTENT_LENGTH);
}).body(converter::convert).build();

image

As a result mapping is always old metric,convert is useless!

@lagudomeze
Copy link
Author

maybe just change mappings/index.vue#L93 to v3 is fine?

lagudomeze added a commit to lagudomeze/spring-boot-admin that referenced this issue Sep 18, 2022
SteKoe added a commit that referenced this issue Sep 18, 2022
SteKoe added a commit that referenced this issue Sep 18, 2022
SteKoe added a commit that referenced this issue Sep 18, 2022
@SteKoe
Copy link
Contributor

SteKoe commented Sep 18, 2022

Hi @lagudomeze,

thanks for filing this issue and providing a PR 😍!
We have checked your inquiry and tested it using Spring Boot 1.4 up to 3.0. Sadly, your change breaks accessing metrics on Spring Boot services using versions 2.0 and 2.1. Nevertheless, we have implemented your suggested change in a slightly different way and are now checking both ApiVersions (V2 -> Spring Boot 2.0/2.1, V3 -> Spring Boot >2.2).

Regards,
SteKoe

@SteKoe SteKoe closed this as completed Sep 18, 2022
erikpetzold added a commit that referenced this issue Jan 6, 2023
* Changed maven compiler to Java 17

Removed findbugs jsr305 dependency in favor of jetbrains annotations to prevent errors in javadoc creation

* Fix UnitTest

* Fix admin-server tests, formatting etc.

* Fix Nullable imports

* Set up JDK 17

* Introduce Spring Boot 3

* Introduce Spring Boot 3

* fix wiremock setup

* Add explicit eureka-client version
New Spring Cloud version for Spring Boot 3

* moved from node-sass to sass

* Change java version to 17 in github actions

* cleanup versions

* set java-version to 17 in release-to-maven-central.yml

* use nexus-staging-maven-plugin 1.6.12

* spring-boot-admin-sample-zookeeper deactivated (nexus-staging-maven-plugin fails)

* reactivated spring-boot-admin-sample-zookeeper

* replace developers in pom by codecentric generic part

* chore: update pipeline to use windows-latest

* updated nexus-staging-maven-plugin to 1.6.13

* fix: publish package step

* feat: merge new UI

* chore: update spring boot and spring cloud

* chore: fix errors in IDE

* chore: update Hazelcast and add shutdown to tests

* chore: ceckstyle

* chore: fix windows build

* chore: update spring boot to 3.0.0-M3

* chore: padding to the panel

* fix: base path of build may not start with leading slash for ressources

* fix: buttons do not show current selected logging level

* fix: toggle button for scope in caches view is shown, even when there is just one instance only

* chore: remove logging

* feat(AuditEvents): migrate to new UI

* chore: nicer panel

* fix: show user name in user menu when opened

* fix: visibility of services that are down, offline or oos

* fix: metadaten overflow

* fix: audit events error

* fix: debug email address

* fix: wallboard display glitch in Safari

* fix: application list version jumping

* fix: show error message on top of health details

* chore: run npm tests in test phase (allows to skip tests)

* fetchHealth: validateStatus: null

* chore(deps): update spring-cloud version

* feat: update spring boot to 3.0.0-M4

* chore: merge changes from master

* chore: merge origin/master

* fix: remove test data

* feat: add toasts and replace some modals

* chore: refactoring

* chore: remove sba-modal-conform dialog and refactoring

* fix: notification-filter-settings.vue

* fix: trailing slash in path is not allowed in spring boot 3 anymore

* chore: better UX for application actions

* feat: adds notification center which allows to manage existing notification settings

* chore: refactoring of navigation

* chore: toast theming

* chore: toast theming

* refactoring: composition api

* refactoring: notification filters

* chore: fix tests

* chore: mobile view

* refactoring: use composition API

* chore: split spring profiles into dedicated files as required by Spring Boot 3

* chore(#2122): check for ApiVersion.V3

* chore: separate buttons in application list item actions

* chore(#2122): check for ApiVersion.V3

* chore: set SNAPSHOT versions

* chore: add more informative error message to login screen

* chore: remove windows build to save resources

* chore: fix test

* chore: update workflow files

* chore: update to Spring Boot 3.0.0-RC1

* chore: fix checkstyle

* feat: implement different toast notification center

* chore: small adjustments on UI for better browser compatability

* feat: nicer docs :)

* chore: prettier & linter

* chore: adapt docs to Spring Boot 3

* chore: restructure readme and contribution guidlines

* chore: fix tests by adding some more

* * Path Matcher
* Security Config

* Added .DS_STORE to gitignore

* feat: WebSocketRegistrator

* chore: adapt RC2 changes

* Fixed import order

* Remove "Fixe" :D

* WIP - Partially Fixed NavbarLink spec.

* chore: update to Spring Boot 3.0.0 GA

* do not authorize requests that get dispatched async

With spring-projects/spring-security#11107
the default to filter all dispatcher types was changed to true.

* Removed deprecated passwordEncoder

* formatting for security config

* chore: fix user menu

* chore: work on login page

* feat: improve notifiers

* Refactored redundant loading of login settings

* formatter fix

* chore: do not wrap tags to achieve a nicer ui result

* chore: log error when configuring view

* chore: zwischenstand

* chore: useApplicationStore should not reset refs

* pin old version of versions plugin as new version does not work in release

* fix group id for plugin

* add issue as reference

* update spring cloud version

* chore: set release version of spring cloud

* chore: add tests for useApplicationStore

* chore: porting config for toasts

* chore: fix test in store.spec.js

* chore: show error in wallboard, too, when server connection is lost

* normalize homepage url

with spring framework 6 the pattern matching does not match trailing
slashes by default, so forwarding did not work when running with context
path and reloading the page

fixes #2175

* do not normalize path to empty string

* #2175: Normalized homepage url for serlvet variant

* #2175: Generalized normalizing of homepage url + unittest

* #2175: Generalized normalizing of homepage url + unittest

* #2175: Generalized normalizing of homepage url + unittest

* #2183: Fixed urls on about page

* #2185: Added new view for Spring Boot 3 Actuator HttpExchanges (#2186)

* #2185: Added new view for Spring Boot 3 Actuator HttpExchanges

* #2185: Removed view for httptrace since it has been replaced by httpexchange in spring boot 3 actuator

* Revert "#2185: Removed view for httptrace since it has been replaced by httpexchange in spring boot 3 actuator"

This reverts commit 1dd95c8.

* #2185: Revoked deletion of httptrace mock-data since it might still be used in 2.x appplications with sba 3.x

* chore: update spring boot to 3.0.1

* support comma-separated tag values (#2179)

(cherry picked from commit b9dc801)

* add javadoc

* fix formatting

* clean up pom

* remove Jolokia actuator, is not supported by Spring Boot 3

* do not set junit version manually

Co-authored-by: ulrichschulte <ulrich.schulte@codecentric.de>
Co-authored-by: Andreas Fritz <mail@andreasfritz.de>
Co-authored-by: Stephan Köninger <stephan.koeninger@codecentric.de>
Co-authored-by: Stephan Köninger <github@stekoe.de>
Co-authored-by: Fedor Bobin <fuudtorrentsru@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants