Feat/018 application build info - #37
Open
hendrikebbers wants to merge 7 commits into
Open
Conversation
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…018) Add a read-only com.openelements.spring.base.info package to spring-services-core answering "which build is running, and what is it made of?": - ApplicationInfo/GitInfo/SbomSummary/SbomComponent/SbomDocument immutable record model (JSpecify @NullMarked, normalised collections) - CycloneDxReader: package-private Jackson tree parser, degrades to empty + WARN, ignores unknown fields, no new dependency - ApplicationInfoService: coordinates + two-source Git resolution (git.properties wins over build.commit), SBOM autodetect matching Spring Boot's SbomEndpoint order, eager parse cached in final fields - ApplicationInfoProperties (openelements.info.sbom.*) - ApplicationInfoAutoConfiguration: JPA-independent, @AutoConfigureAfter ProjectInfoAutoConfiguration, @ConditionalOnMissingBean; registered as a second AutoConfiguration.imports entry - No build timestamp, no REST endpoint (SBOM is an attack-surface map) Tests: 40 unit/context tests (reader, service precedence, licenses, no-JPA context, own-bean substitution, malformed-SBOM startup) plus a real cyclonedx-maven-plugin SBOM fixture. README Features updated. Refs spec docs/specs/018-application-build-info Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
… (spec 018 review) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…uality review) Add a defensive-edge-cases CycloneDX fixture (absent bomFormat, null/non-scalar fields, non-object array entries, non-array licenses, expression fallback), build.commit.time parse success/failure cases, a blank commit.id.abbrev fallback, and record null-collection normalisation tests. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request implements the Application Build & SBOM Info feature in
spring-services-core, providing a new backend-only service to answer "which build is running, and what is it made of?" via artifact coordinates, Git commit information, and a parsed CycloneDX SBOM. The implementation includes an immutable record model, a Jackson-based SBOM parser, configuration properties, a service with auto-configuration, and comprehensive tests and documentation. No new dependencies are added, and the feature is designed to work without JPA and to be easily overridden by applications.New Application Build & SBOM Info feature:
ApplicationInfoServiceand supporting immutable record model (ApplicationInfo,GitInfo,SbomSummary,SbomComponent, etc.) for exposing build, Git, and SBOM summary information. The service is backend-only, does not expose a REST endpoint, and is safe by default.CycloneDxReaderfor robust, non-throwing parsing of CycloneDX SBOM files, summarizing licenses and components with support for various SBOM and license scenarios.ApplicationInfoProperties(openelements.info.sbom.enabledandopenelements.info.sbom.location) for feature configuration, with sensible defaults and override support.ApplicationInfoAutoConfigurationfor auto-registering the service unless overridden, ensuring availability even without JPA.Documentation and Specification:
This feature is now complete and ready for use.