2
votes

I have a simple project with Spring Actuator, also i have a maven plugin generating git.properties (resides in classes directory).

However when i run my app, /actuator/info request shows:

{
"git": {}
}

Documentation says autoconfigure should pick up properties automatically https://docs.spring.io/spring-boot/docs/current/reference/htmlsingle/#production-ready-application-info-git

1
Does your jar contain /BOOT-INF/classes/git.properties? If yes, try to set management.info.git.mode = full - Alexander Pankin
i've tried with management.info.git.mode = full and without. - razor
ok, found problem, git.properties 'looked' like properties file, but had {} (json format). after changing formatting (in plugin conf) it works - razor

1 Answers

3
votes

My mistake, git.properties was not a 'properties' file in fact. I didn't see {} around a file content.

after changing configuration/format to properties in git-commit-id-plugin plugin, it works (plugin was generating git info in json)