[NOOK-162] 게시물 파싱 임시 추적 로그 추가 - #112
Conversation
6c4e208 to
e7d3cb3
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 6c4e208ed2
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| place.photoEvent("google.photo.media.failed", PHOTO_MEDIA_STAGE, sequence, exception), | ||
| exception, | ||
| ) | ||
| }.getOrNull() ?: return null |
There was a problem hiding this comment.
Preserve the warning for photo-media lookup failures
When the Google photo media request throws, this branch converts the exception to null and returns before the outer fetch failure handler can see it. The only replacement is eventLogger.warn, but the new ProcessingLog implementation routes that extension through atDebug(), so deployments running at INFO lose the operational warning that the previous storePhoto catch emitted; retain a normal logger.warn for this failure path.
Useful? React with 👍 / 👎.
| ProcessingLogEvent( | ||
| action = "place.provider.search.completed", | ||
| flow = "place", | ||
| stage = "search", |
There was a problem hiding this comment.
Propagate the post context into provider worker threads
When Naver or Kakao is invoked through CompositePlaceSearchProvider, the provider call runs on the plain fixed thread pool created by PlaceSearchConfig, so the caller's MDC is not available here. Because these new provider events also omit sourcePostId, their per-provider results cannot be correlated with the source post; copy/restore the MDC around submitted work or carry the post ID into these events.
Useful? React with 👍 / 👎.
| ProcessingLogEvent( | ||
| action = "openai.response.completed", | ||
| flow = "content-inference", | ||
| stage = name, |
There was a problem hiding this comment.
Use the invoking flow for shared OpenAI events
This adapter is shared by post inference, place-clue extraction, candidate selection, and place-tag extraction, but every completion event is labeled content-inference. Consequently calls made under the place and place-tags pipelines are misclassified—and may conflict with the surrounding MDC value—so flow-based searches omit or incorrectly group those OpenAI stages; derive the flow from the operation or pass it into requestStructured.
Useful? React with 👍 / 👎.
| "instagram.provider.request.failed", | ||
| "failure", | ||
| startedAt, | ||
| mapOf("http.status_code" to statusCode), |
There was a problem hiding this comment.
Include failure fields in provider failure events
When an Apify or Bright Data HTTP request fails, the structured event records only the status code. Attaching the exception as the logging cause does not populate the declared failure.type and failure.reason fields, so searches using those standardized fields cannot classify provider failures; add bounded exception type and reason values to this event.
Useful? React with 👍 / 👎.
변경 내용
[PostParcingTracker]접두어와 공통 stage/status/duration/error 필드를 사용합니다.목적
장소 파싱 흐름 개편 중 어느 단계에서 왜 실패했는지, 외부 provider 응답과 처리 시간이 어땠는지 한 요청 단위로 추적하기 위함입니다.
검증
./gradlew check