Skip to content

APiGen BOM (Bill of Materials) ​

Centralized dependency version management for APiGen modules with security patches and compatibility guarantees.

Overview ​

The Problem: Dependency Hell ​

Before APiGen BOM:

groovy
// Project A: apigen-core
dependencies {
    implementation 'org.springframework.boot:spring-boot-starter-web:3.2.0'
    implementation 'com.google.guava:guava:32.0.0-jre'  // ⚠️ CVE-2023-2976
}

// Project B: apigen-security  
dependencies {
    implementation 'org.springframework.boot:spring-boot-starter-web:4.0.2'  // ❌ Version conflict!
    implementation 'com.google.guava:guava:33.0.0-jre'   // ❌ Different version!
}

// Your Application
dependencies {
    implementation 'com.jnzader:apigen-core:1.0.0'
    implementation 'com.jnzader:apigen-security:1.0.0'
}

Result:
// Gradle uses highest version → Spring Boot 4.0.2
// But apigen-core was built with 3.2.0 → Runtime errors!
// NoSuchMethodError, ClassNotFoundException

After APiGen BOM:

groovy
dependencies {
    // ✅ Single source of truth for all versions
    implementation platform('com.jnzader:apigen-bom:1.0.0-SNAPSHOT')
    
    // ✅ No version conflicts - all APiGen modules use same versions
    implementation 'com.jnzader:apigen-core'
    implementation 'com.jnzader:apigen-security'
    implementation 'com.jnzader:apigen-search'
    
    // ✅ Third-party dependencies also managed
    implementation 'org.mapstruct:mapstruct'  // BOM provides version
    implementation 'com.google.guava:guava'   // BOM provides patched version
}

Result:
// ✅ Spring Boot 4.0.2 everywhere
// ✅ Guava 33.5.0-jre with CVE patches
// ✅ 100% compatibility guaranteed
// ✅ Zero version conflicts

Time Saved:

  • Manual dependency management: 2-4 hours per project (conflicts, CVE research)
  • APiGen BOM: 5 minutes (add platform import)
  • Result: 95% time reduction

Purpose ​

The BOM ensures all APiGen modules and their dependencies use compatible versions, preventing version conflicts in your project. It also includes security patches for transitive dependencies with known CVEs.

Usage ​

Gradle:

groovy
dependencies {
    implementation platform('com.jnzader:apigen-bom:1.0.0-SNAPSHOT')
    implementation 'com.jnzader:apigen-core'
    implementation 'com.jnzader:apigen-security'  // Optional
    implementation 'com.jnzader:apigen-search'    // Optional
}

Maven:

xml
<dependencyManagement>
    <dependencies>
        <dependency>
            <groupId>com.jnzader</groupId>
            <artifactId>apigen-bom</artifactId>
            <version>1.0.0-SNAPSHOT</version>
            <type>pom</type>
            <scope>import</scope>
        </dependency>
    </dependencies>
</dependencyManagement>

Managed Dependencies ​

Core Framework ​

DependencyVersionNotes
Spring Boot4.0.2Latest Spring Boot 4.x
Spring Cloud2025.1.12025 release train
MapStruct1.6.3DTO mapping
Caffeine3.2.3High-performance caching
Resilience4j2.3.0Circuit breaker, retry, rate limiter
SpringDoc OpenAPI3.0.1OpenAPI 3.1 documentation

Security ​

DependencyVersionNotes
JJWT0.13.0JWT authentication

Search Engines ​

DependencyVersionNotes
Elasticsearch8.17.0Full-text search
Algolia4.10.1Hosted search
Meilisearch0.14.2Open-source search
Typesense1.2.0Typo-tolerant search

Graph Databases ​

DependencyVersionNotes
Neo4j Driver5.28.10Cypher queries
Gremlin (TinkerPop)3.7.1Graph traversal
ArangoDB7.12.0Multi-model database

Observability ​

DependencyVersionNotes
Micrometer Tracing1.6.2Distributed tracing
OpenTelemetry1.58.0OTLP exporter
Logstash Encoder9.0Structured logging

Feature Flags ​

DependencyVersionNotes
Togglz4.4.0Feature flag management

Testing ​

DependencyVersionNotes
Testcontainers1.20.3Integration testing
ArchUnit1.4.1Architecture testing
Awaitility4.3.0Async testing

Performance & Query Analysis ​

DependencyVersionNotes
Hypersistence Utils3.14.1N+1 query detection

Security Patches ​

The BOM includes security fixes for transitive dependencies with known CVEs:

DependencyVersionCVEs Fixed
Guava33.5.0-jreCVE-2020-8908, CVE-2023-2976 (insecure temp directory)
Logback1.5.25CVE-2026-1225
Netty Codec HTTP4.2.8.FinalCVE-2025-67735
Rhino1.7.15.1CVE-2025-66453

These overrides ensure secure transitive dependencies even when third-party libraries use vulnerable versions.

APiGen Modules ​

All APiGen modules are version-constrained by the BOM:

ModuleDescription
apigen-coreCRUD base classes, auditing, caching
apigen-exceptionsRFC 7807 error handling
apigen-securityJWT, OAuth2, SAML, 2FA
apigen-codegenCode generation engine
apigen-docsInteractive documentation
apigen-graphGraph database support
apigen-searchFull-text search integration

Compatibility Matrix ​

Java VersionSpring BootAPiGen BOM
25+4.0.2+1.0.0+
21+3.2.0+0.9.0+
17+3.0.0+0.8.0+

Released under the MIT License.