- 결정 28: `INTERNAL_ERROR` retryable=false(레지스트리·코드·문서·기대값) - 결정 29: messaging 카드 검증을 `adapter:outbound:messaging` 테스트로, snakeyaml은 test configuration에서만 - 결정 31: release.yml에 cosign keyless 이미지 서명·검증 job(공식 체크섬 고정 설치, id-token은 그 job만) - persistence-fileserver `ca.api-surface`(P16-new-6), `ca.release-provenance` 제거(BUILD-O3-5 일부) - 에이전트가 세션 재시작으로 중단 — 결과 파일은 오케스트레이터가 작성, 미커밋 `jvm-test-suite` 전환은 패치로 보관 - 통합: messaging CLAUDE.md 충돌(encoder 위치 + test 전용 snakeyaml 문장 병합) 검증: ./gradlew mainCheck, -p build-logic test, -p optional-platforms ci, releaseCheck -PgitRevision 통과. ci verifyDependencyLocks --warning-mode=fail은 web-advanced `WebStreamingSoakIT` 1건(1001 > 1000) 외 통과 — 단독 3회 통과, 경합 가능성으로 ORCH-new-3 행에 기록 Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
185 lines
9.5 KiB
Groovy
185 lines
9.5 KiB
Groovy
plugins {
|
|
// Spring Boot stays on the root build script classpath because two leaves apply it by id
|
|
// (`app-bootstrap`, `sample-portfolio`) and a leaf resolves plugin classes from the root.
|
|
//
|
|
// Spotless, SpotBugs, Error Prone and Spring's dependency-management are NOT here any more. They
|
|
// were declared `apply false` for a `configure(subprojects)` block that applied them to every
|
|
// leaf; build-logic's `ca.quality-conventions` and `ca.java-conventions` apply them now, and a
|
|
// plugin reachable from two classpaths is two versions waiting to differ. Their versions are the
|
|
// same catalog entries either way — build-logic/settings.gradle reads gradle/libs.versions.toml.
|
|
alias(libs.plugins.spring.boot) apply false
|
|
// JMH benchmarks in three leaves (`./gradlew :<leaf>:jmh`); never part of a gate.
|
|
alias(libs.plugins.jmh) apply false
|
|
|
|
// Convention plugin from the included build, applied to the ROOT because the rules it owns are
|
|
// about the repository: the architecture gates. The release version/revision is each leaf's
|
|
// `ca.java-conventions` (ca.release-provenance was removed, BUILD-O3-5). The public-path
|
|
// baseline is app-bootstrap's approval test, the local start-up is scripts/bootstrap-local.sh,
|
|
// and archive hygiene is gone with the revision it cleaned out of every leaf's jar name (review
|
|
// 2026-09-24 BUILD-O3-5).
|
|
id 'ca.architecture'
|
|
}
|
|
|
|
group = 'dev.caskeleton'
|
|
|
|
// A release archive has to name the commit that produced it. The revision rule is the one every
|
|
// leaf's version uses (JavaConventionsPlugin.sourceRevision, tested in build-logic), read here so
|
|
// the tag-only gate and the jars cannot disagree about what counts as a commit id.
|
|
tasks.register('verifyReleaseProvenance') {
|
|
group = 'verification'
|
|
description = 'Fails when the build cannot name the source revision it was produced from.'
|
|
String revision = dev.caskeleton.buildlogic.java.JavaConventionsPlugin.sourceRevision(providers)
|
|
boolean traceable = revision != dev.caskeleton.buildlogic.java.JavaConventionsPlugin.UNKNOWN_REVISION
|
|
outputs.upToDateWhen { false }
|
|
doLast { task ->
|
|
if (!traceable) {
|
|
throw new GradleException('verifyReleaseProvenance: no source revision. A release archive has to name the '
|
|
+ 'commit that produced it; supply -PgitRevision=<sha>, GIT_SHA or GITHUB_SHA.')
|
|
}
|
|
task.logger.lifecycle("verifyReleaseProvenance: OK — revision ${revision}")
|
|
}
|
|
}
|
|
|
|
// One explicit command regenerates every module's Gradle-default lockfile.
|
|
tasks.register('resolveAndLockAll') {
|
|
group = 'build setup'
|
|
description = 'Regenerates dependency locks for all subprojects (requires --write-locks).'
|
|
dependsOn subprojects.findAll { it.childProjects.isEmpty() }.collect { "${it.path}:resolveAndLockAll" }
|
|
}
|
|
|
|
tasks.register('verifyDependencyLocks') {
|
|
group = 'verification'
|
|
description = 'Verifies strict dependency lock state for production CI subprojects.'
|
|
dependsOn subprojects.findAll {
|
|
it.childProjects.isEmpty() && it.path != ':sample-portfolio'
|
|
}.collect { "${it.path}:verifyDependencyLocks" }
|
|
}
|
|
|
|
// feature-developer-experience-contract D3 — the ordered local bootstrap lifecycle is
|
|
// scripts/bootstrap-local.sh (compile, Docker preflight, dependency wait, migrate-and-start, smoke).
|
|
|
|
// ---------------------------------------------------------------------------------------------
|
|
// Lifecycle.
|
|
//
|
|
// :<leaf>:check that leaf — compile, its tests, Spotless, Checkstyle, Error Prone
|
|
// check every leaf's check (Gradle matches the name across projects)
|
|
// architectureCheck dependency direction + purity + app-bootstrap whole-repository ArchUnit
|
|
// qualityCheck SpotBugs + FindSecBugs across every leaf (ca.quality-conventions)
|
|
// ci the pull-request gate: leaf checks + architectureCheck + qualityCheck
|
|
// mainCheck the main-branch stage: environment contract, full-boot qualification,
|
|
// sample web contract, public-path baseline, transport and messaging
|
|
// qualification lanes, and each leaf's document-contract lanes
|
|
// integrationCheck the declared strict integration lanes (several need a container runtime)
|
|
// releaseCheck the tag-only checks: release provenance + public path snapshot (not `ci`
|
|
// again — a tag is cut from a main commit the PR and main stages ran on)
|
|
//
|
|
// A leaf's check is that leaf's; a repository question gets a repository task named after it.
|
|
// Task PATHS, not TaskProviders: a leaf's tasks are created by convention plugins after the root is
|
|
// evaluated, and a path is resolved when the task graph is built.
|
|
// ---------------------------------------------------------------------------------------------
|
|
List<String> leafPaths = subprojects.findAll {
|
|
it.childProjects.isEmpty() && it.path != ':sample-portfolio'
|
|
}.collect { it.path }.toSorted()
|
|
|
|
tasks.register('qualityCheck') {
|
|
group = 'verification'
|
|
description = 'Runs SpotBugs and FindSecBugs across every production CI leaf.'
|
|
dependsOn leafPaths.collect { "${it}:qualityCheck" }
|
|
}
|
|
|
|
tasks.register('configContractCheck') {
|
|
group = 'verification'
|
|
description = 'Runs the environment contract owned by the composition root.'
|
|
dependsOn ':app-bootstrap:verifyEnvKeys'
|
|
}
|
|
|
|
// A lane that needs an input this build was not given (the Redis topology coordinates, the protected
|
|
// AWS sandbox authority) is explicit-only: the aggregate leaves it out and names it when it runs
|
|
// (review NEW-16). The sample's integration lanes are here although the sample is not a production
|
|
// leaf, because nothing else ran its strict PostgreSQL lanes (review NEW-13e).
|
|
tasks.register('integrationCheck') {
|
|
group = 'verification'
|
|
description = "Runs every production CI leaf's and the sample's integration-category test lanes. Several need a container runtime."
|
|
dependsOn leafPaths.collect { "${it}:integrationTestLaneCheck" }
|
|
dependsOn ':sample-portfolio:integrationTestLaneCheck'
|
|
}
|
|
|
|
tasks.named('architectureCheck') {
|
|
dependsOn leafPaths.collect { "${it}:architectureTestLaneCheck" }
|
|
}
|
|
|
|
tasks.register('systemTestCheck') {
|
|
group = 'verification'
|
|
description = "Runs every production CI leaf's full application/system test lanes."
|
|
dependsOn leafPaths.collect { "${it}:systemTestLaneCheck" }
|
|
}
|
|
|
|
tasks.register('qualificationCheck') {
|
|
group = 'verification'
|
|
description = 'Runs repository/build-behavior qualification that is intentionally outside local leaf checks.'
|
|
dependsOn tasks.named('systemTestCheck')
|
|
dependsOn leafPaths.collect { "${it}:auxiliaryStyleCheck" }
|
|
}
|
|
|
|
tasks.register('sampleWebContractCheck') {
|
|
group = 'verification'
|
|
description = 'Runs the real-server sample HTTP/OpenAPI contract source set without pulling every sample lane into CI.'
|
|
dependsOn ':sample-portfolio:webSystemTest'
|
|
}
|
|
|
|
// Each lane below names its tests and rejects skips; these two only aggregate them.
|
|
tasks.register('conditionalTransportQualification') {
|
|
group = 'verification'
|
|
description = 'Runs the no-skip GraphQL, gRPC and WebSocket transport lanes and the opt-in classpath contract.'
|
|
dependsOn ':adapter:inbound:graphql:graphqlTransportQualificationTest',
|
|
':adapter:inbound:grpc:grpcTransportQualificationTest',
|
|
':adapter:inbound:websocket:websocketTransportQualificationTest',
|
|
':app-bootstrap:conditionalTransportBuildContractTest'
|
|
}
|
|
|
|
tasks.register('verifyMessagingContracts') {
|
|
group = 'verification'
|
|
description = 'Qualifies the application integration-event contract and the shared envelope schema.'
|
|
dependsOn ':application-core:messagingApplicationContractQualificationTest',
|
|
':shared-contract:messagingSharedSchemaQualificationTest',
|
|
':sample-portfolio:messagingSampleContractQualificationTest'
|
|
}
|
|
|
|
tasks.register('ci') {
|
|
group = 'verification'
|
|
description = 'The pull-request gate: every production CI leaf check plus the architecture and quality gates.'
|
|
dependsOn leafPaths.collect { "${it}:check" }
|
|
dependsOn tasks.named('architectureCheck')
|
|
dependsOn tasks.named('qualityCheck')
|
|
}
|
|
|
|
tasks.register('mainCheck') {
|
|
group = 'verification'
|
|
description = 'The main-branch stage: the gates that are not worth a pull request\'s wait.'
|
|
dependsOn leafPaths.collect { "${it}:mainCheck" }
|
|
dependsOn tasks.named('configContractCheck')
|
|
dependsOn tasks.named('qualificationCheck')
|
|
dependsOn tasks.named('sampleWebContractCheck')
|
|
dependsOn tasks.named('verifyPublicPathSnapshot')
|
|
dependsOn tasks.named('conditionalTransportQualification')
|
|
dependsOn tasks.named('verifyMessagingContracts')
|
|
dependsOn ':adapter:inbound:graphql:graphqlStableTest'
|
|
}
|
|
|
|
// The deny-by-default public path baseline: app-bootstrap's approval-test lane under its old name.
|
|
// `-PapprovePublicPathChange` rewrites the baseline after review.
|
|
tasks.register('verifyPublicPathSnapshot') {
|
|
group = 'verification'
|
|
description = 'Fails when the shipped public path default drifts from docs/security/public-paths-snapshot.txt.'
|
|
dependsOn ':app-bootstrap:publicPathSnapshotTest'
|
|
}
|
|
|
|
// The checks that only matter for a release artifact. Not `ci` again: a release tag is cut from a
|
|
// main commit that the pull-request gate and the main stage already ran on (review BUILD-중복-6).
|
|
tasks.register('releaseCheck') {
|
|
group = 'verification'
|
|
description = 'The tag-only checks: release provenance and the public path baseline.'
|
|
dependsOn tasks.named('verifyReleaseProvenance')
|
|
dependsOn tasks.named('verifyPublicPathSnapshot')
|
|
}
|