Skip to content

Commit 2d74773

Browse files
authored
propose: @FeignClient is a caller, not an exposer (#25)
* propose: @FeignClient is a caller, not an exposer Reported-by: review on cross_service_smoke A @FeignClient method is a client — it makes outbound HTTP calls. But the indexer emits an EXPOSES edge from every Feign method to a consumer-side Route node, treating the caller as if it also exposed the endpoint. The same wire ends up represented as two unrelated Route nodes (one consumer-side in the caller, one endpoint-side in the server) and the HTTP_CALLS edge lands on the wrong one, producing intra_service match labels for what are really cross-service calls. The root cause: ast_java.py:2178 already distinguishes kind=http_consumer (Feign) from kind=http_endpoint (Controller), but build_ast_graph.py:1354-1364 emits EXPOSES unconditionally per RouteDecl. The semantic distinction was made; it's just not honoured at emission. Single-PR fix (~150 LOC): suppress EXPOSES emission when kind=http_consumer, extend the cross-service matcher to pair consumer Routes against endpoint Routes across microservices, add pass4_feign_exposes_suppressed counter to graph_meta with new _META_PR_FEIGN tier. Status: draft. Six [TBD] items including a recommendation to audit ASYNC_CALLS for the symmetric bug before implementation. * propose: fold ASYNC_CALLS audit verdict into §8 and [TBD-6] Audited all five RouteDecl emission sites in ast_java.py for the symmetric Feign-style EXPOSES bug. Verdict: bug does not exist on the async side. Async uses structurally different annotations per direction (@KafkaListener consumer vs KafkaTemplate.send producer); only listeners emit RouteDecl, producers emit OutgoingCall. Verified empirically on cross_service_smoke fixture. Fix stays HTTP-only.
1 parent 79a99a1 commit 2d74773

1 file changed

Lines changed: 441 additions & 0 deletions

File tree

0 commit comments

Comments
 (0)