# 주제: messaging-nats-experimental / messaging-pulsar-experimental 공통 측정 # revision: 21234e38cdb9a926cbc92bb97a2aee2e4a7d2916 # ---- (1) PreSendRejection 이 같은 클래스 두 벌이다 ---- # NatsPreSendRejection.java 65줄 # PulsarPreSendRejection.java 65줄 # command: 패키지·클래스명·도메인어 3개(publish/send operation, connection/producer closed, # subject/topic)를 치환한 뒤 diff # exit: 1 — 차이는 javadoc 한 문단의 **줄바꿈 위치 4줄뿐**이다. 문장 내용은 동일하다. # 15,18c15,18 # < *
The OP throws this only when it knows the send never left the client: an # < * argument the SDK refused, a CLOSED, a UNIT the client could not # --- # > *
The OP throws this only when it knows the send never left the client: an argument
# > * the SDK refused, a CLOSED, a UNIT the client could not resolve.
# => 필드·생성자 2개·requireCode·code() 가 전부 동일. 같은 클래스가 두 패키지에 있다.
#
# 두 javadoc 이 같은 과거 결함을 인용한다:
# "Classification used to work by reading the exception's class simple name and matching
# substrings — "Timeout" meant ambiguous, anything else meant rejected. … A class name is not
# part of any SDK's contract … And defaulting the unknown case to REJECTED tells the caller
# nothing was transmitted, so a caller that republishes under a new identity duplicates a
# message the server may well have stored."
#
# 같은 질문("이 쓰기가 서버에 닿았는가")에 대한 접근이 플랫폼에 네 가지 있다:
# messaging-kafka KafkaPublishFailureClassifier 허용목록 7종 + 모호 기본값
# messaging-rabbit RabbitPublishFailureClassifier confirm/return 상관 + 분류기
# messaging-nats NatsPreSendRejection 명시적 pre-send 예외만 REJECTED
# messaging-pulsar PulsarPreSendRejection 동
# 앞의 둘은 SDK 예외를 분류하고, 뒤의 둘은 "분류하지 않는다" 를 선택했다.
# 뒤의 둘의 판단이 더 보수적이며 그 근거가 명시적이다 — 다만 그 판단이 두 번 구현되어 있다.
# ---- (2) 선언 의존 7개 중 4개가 import 0건 (양쪽 동일) ----
# command: git grep -h "^import dev.caskeleton.messaging.