Skip to content

[Feature] Version-aware hensu-server native binary #77

Description

@alxsuv

Description

Currently the hensu-server native image always reports hensu-server 0.1.0-SNAPSHOT in its Quarkus startup banner, regardless of which GitHub release tag (e.g. server/v0.1.0-beta.1) the artifact was built
from. Make the binary's reported version match the release tag so downloads from the GitHub Releases page are self-identifying.

Scope

  • Build: In root build.gradle.kts:11, replace the literal version = "0.1.0-SNAPSHOT" with a parameterized read using a distinct property name (e.g. findProperty("releaseVersion")?.toString() ?: "0.1.0-SNAPSHOT"). A distinct name is required because Gradle's project.version defaults to "unspecified", which would bypass an elvis fallback on findProperty("version").
  • CI: In .github/workflows/release-server.yml (resolve-version step at lines 23–34 already exports $VERSION from a server/v* tag), append -PreleaseVersion=$VERSION to the existing native build
    invocation. Do not introduce a new tag-parsing regex.
  • Runtime: No code change required. Quarkus' default startup banner already interpolates quarkus.application.version, which the Quarkus Gradle plugin auto-populates from the project version. Skip any
    @ConfigProperty injection or IVersionProvider work.

Acceptance criteria

  • Local ./gradlew :hensu-server:quarkusDev (no -PreleaseVersion) still prints hensu-server 0.1.0-SNAPSHOT.
  • A release build with -PreleaseVersion=0.1.0-beta.1 prints hensu-server 0.1.0-beta.1 in the banner.
  • Native image produced by release-server.yml for tag server/v0.1.0-beta.1 reports 0.1.0-beta.1 on startup.
  • No new reflection, classpath scanning, or runtime config lookups introduced (native-safety invariants preserved).

Out of scope

  • Adding a dedicated --version CLI subcommand.
  • Changing the GitHub release tag naming convention.
  • Native-image integration tests (tracked separately; see README.md:319).

Metadata

Metadata

Assignees

Labels

area: native-imageGraalVM compilation, reflection metadata, and SubstrateVM issuesarea: serverQuarkus backend, REST endpoints, and SSE communicationsize: quick-winTasks you can crush in 30 mins (helps build momentum)type: featureNew feature or request

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions