Search code examples
javamavenbuildquarkusquarkus-rest-client

How to detect build time at runtime in Quarkus?


I am pretty new to Quarkus and I can't seem to find a way to obtain build information like build version or last built time at run time. Any insights will be appreciated.


Solution

  • You would need to configure Maven to record that information in application.properties. Something like: How to access maven.build.timestamp for resource filtering.

    Then at runtime you would read the properties and extract what you need. Likely something like How to read properties file inside jar?