Skip to content

fix: 2026-07-27 평가·독푸딩 발견 결함 전량 수정 (v1.4.1) - #32

Merged
baekchangjoon merged 1 commit into
mainfrom
fix/eval-dogfood-findings
Jul 27, 2026
Merged

fix: 2026-07-27 평가·독푸딩 발견 결함 전량 수정 (v1.4.1)#32
baekchangjoon merged 1 commit into
mainfrom
fix/eval-dogfood-findings

Conversation

@baekchangjoon

Copy link
Copy Markdown
Collaborator

배경

2026-07-27 평가·독푸딩 리포트(서브에이전트 산출, 코디네이터 교차 검증)의 발견 결함을 전량 수정한다. 모든 수정에는 결함을 발견한 방법 자체를 인코딩한 회귀 테스트가 딸려 있다.

수정 내역 (15항목)

agent — 제어 엔드포인트

  • BUG-1 (major): agent만 부착한 JVM이 main 리턴 후 hang(non-daemon HTTP-Dispatcher) → daemon executor + daemon 스레드에서 기동, 기동 실패는 IOException으로 전파. 테스트: AgentJvmExitE2E(자식 JVM 자력 종료 + aggregate.exec, 발견 방법 그대로) + controlServerThreadsAreDaemon(jstack 관찰 인코딩).
  • BUG-5: 미존재 testId text stop 거짓 200 → 양 경로 404. BUG-6: format 오타 무검증 → 400(store 미소비). U7: POST 전용(405) + 비루프백 바인드 무인증 경고. 테스트: ControlEndpointContractTest 5종.
  • stop(): graceful executor 종료(interrupt로 인한 .exec 절단 방지).

agent — 관측성

  • instrumentFailures 카운터 + WARN: Instrumenter가 던지면(실전 −22.7% 무음 손실 사고의 실패 모드) 카운트+경고. 테스트: InstrumentFailureSignalTest(NoSuchMethodError=ASM clash 재연).
  • BUG-4: 미지/불량 옵션 기동 WARN (AgentOptionsParseWarningsTest, destdirr 시나리오 그대로). BUG-7: 로그 stderr화(surefire 채널 오염 해소). BUG-8: summary 프리픽스 중복 제거 (LogChannelTest).
  • manifest jacocoVersion: 하드코딩 제거, 임베드 jacoco-core의 JaCoCo.VERSION에서 파생하되 3세그먼트 축약형 유지(출력 스키마 보존; BootstrapManifestTest + SpecAcceptanceE2E는 하드코드 대신 파생값 단언으로 카나리 매트릭스에도 안전).
  • PROBE_COUNTS 멀티클래스로더 제약은 문서화(수정 시 jacoco 내부 리플렉션 표면 확대 — 의도적 보류).

testkit

  • BUG-2 (major): JUnit5 병렬 @ParameterizedTest per-test exec 무음 소실(공유 testId → retry-overwrite 레이스) → invocation별 고유 testId FQCN#method[N]. 공용 TestIds 헬퍼로 인프로세스·블랙박스(HTTP) extension 양쪽 적용(1차 수정이 HTTP 쪽을 누락했던 것을 코드 리뷰가 적발). JUnit4 PjacocoRulegetMethodName()이 이미 [N] 포함으로 감사 통과. 테스트: InvocationUniqueTestIdTest(파생 규칙) + ParameterizedInvocationEndToEndTest(런처로 실제 실행, stub 제어 서버가 받은 testId 3종 검증 — 호출 지점 누락도 잡는 행동 테스트).
  • U3: testkit jar 4종에 POM+pom.properties 내장(install-file transitive 보존), verifyJarEmbedsPom이 check에 배선되고 CI에도 추가(가드 미실행 갭 해소), 좌표를 태스크 입력으로 선언(버전 변경 시 stale 방지) + config-cache 안전 provider.

gradle-plugin

  • P4-A 캐시 가드 flaky 안정화: --no-watch-fs(외부 삭제 ↔ 데몬 VFS 레이스 원인 주석 포함).

docs/version

  • 1.4.1 lockstep bump(RELEASING.md 체크리스트 전체). README ko/en: 좌표 1.4.1 동기화(1.3.0 표류 해소), binary stop/persist/X-Pjacoco 헤더, 강화된 엔드포인트 계약(≤1.4.0 대비 명시 — 릴리스 노트 소스), install-file 절차, Maven 기본 출력 위치, droppedProbes 단일-active 휴리스틱 한계. v1.3.0 이름 변경 역사 배너는 원복(리뷰 적발).

소비자 영향 (릴리스 노트 반영 필요)

  • stop 미존재 testId: text 경로 200→404 / 미지원 format→400 / 비-POST→405 (testkit은 best-effort라 무영향; 커스텀 하니스는 확인 필요)
  • 파라미터화/반복 테스트 exec 파일명: FQCN#method.execFQCN#method[N].exec (invocation별)
  • agent 로그 stdout→stderr

검증

  • 전체 회귀 green: test(전 모듈) + :agent:integrationTest :agent:e2eTest :agent:e2eJakartaTest :agent:e2eCondyTest + verify 4종 (로컬 6m4s) — 리뷰가 적발한 e2eTest red(SpecAcceptanceE2E 2건)까지 수정 후 재확인
  • maven-plugin 1.4.1 패키징 성공, P4-A 가드 3회 연속 green, actionlint 통과
  • 리뷰 2종 완료: spec-compliance(15항목 커버리지 표, major 1건 → README 역사 배너 원복) + code-quality(12건 → 전량 수용: e2e red 2건·BUG-2 HTTP extension 누락·GAV staleness·config-cache·CI 가드 미실행·기동 실패 무음 등)

🤖 Generated with Claude Code

https://claude.ai/code/session_01FavJfhdcNAHZKWvmSBVLYZ

Every fix carries a regression test that encodes HOW the defect was found.

Agent — control endpoint:
- BUG-1 (major): an agent-only JVM hung after main returned — the JDK
  HTTP-Dispatcher thread was non-daemon and the shutdown hook that stops
  the server only runs once shutdown has begun. The server now uses a
  daemon executor and starts from a daemon thread; AgentJvmExitE2E
  re-enacts the discovery (child JVM must exit by itself and write
  aggregate.exec).
- BUG-5: text stop for an unknown testId returned a false 200; now 404
  on both text and binary paths.
- BUG-6: unsupported format values (e.g. "bianry") were silently treated
  as text; now 400 without consuming the in-flight store.
- U7: all control endpoints are POST-only (405 otherwise) and binding a
  non-loopback address logs an explicit no-auth warning.

Agent — observability:
- instrumentFailures counter + rate-limited WARN when jacoco's
  Instrumenter throws: this silent catch cost -22.7% instructions in a
  real app (ASM clash) and was only found by diffing against vanilla.
- BUG-4: unknown/malformed -javaagent options now produce startup WARNs
  (a typoed destdirr silently sent output to the default dir).
- BUG-7: agent logs go to stderr — stdout is surefire's forked-JVM
  channel ("Corrupted channel" warning + dumpstream every build).
- BUG-8: summary() no longer embeds the [pjacoco] prefix AgentLog adds.
- manifest jacocoVersion comes from the embedded jacoco-core's
  JaCoCo.VERSION instead of a hardcoded "0.8.12".
- CoverageBridge PROBE_COUNTS name-keying documented as a known
  multi-classloader limitation (classId keying would widen the
  reflection surface into jacoco internals).

testkit:
- BUG-2 (major): under JUnit 5 parallel execution, @ParameterizedTest
  invocations shared one testId and start()'s retry-overwrite replaced a
  sibling's in-flight store — per-test .exec silently lost. Template
  invocations now get invocation-unique testIds (FQCN#method[N]).
- U3: testkit jars embed their publication POM + pom.properties
  (META-INF/maven) so `mvn install:install-file -Dfile=<jar>` keeps GAV
  and transitive deps; verifyJarEmbedsPom (wired into check) asserts it.

gradle-plugin:
- P4-A cache guard stabilized with --no-watch-fs: the reused TestKit
  daemon's retained VFS could miss the test's external deletion of
  build/pjacoco (macOS event race) and wrongly report :test UP-TO-DATE.

Docs/version:
- Version bumped to 1.4.1 across build.gradle.kts, maven-plugin pom,
  samples, and README (README literals had drifted at 1.3.0 — consumers
  copy-pasting got the version with the ASM instrumentation bug).
- README (ko/en): binary stop + persist + X-Pjacoco-* headers, the
  tightened endpoint contract, install-file walkthrough, Maven default
  output dir, per-invocation parameterized testIds, and the
  single-active droppedProbes heuristic's limits.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FavJfhdcNAHZKWvmSBVLYZ
@baekchangjoon
baekchangjoon merged commit e7d824a into main Jul 27, 2026
8 checks passed
@baekchangjoon
baekchangjoon deleted the fix/eval-dogfood-findings branch July 27, 2026 14:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant