Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

investigate ClusterActorLoggingSpec #795

Closed
pjfanning opened this issue Nov 17, 2023 · 6 comments · Fixed by #1410
Closed

investigate ClusterActorLoggingSpec #795

pjfanning opened this issue Nov 17, 2023 · 6 comments · Fixed by #1410
Assignees
Labels
build sbt or build of the project help wanted Extra attention is needed

Comments

@pjfanning
Copy link
Contributor

pjfanning commented Nov 17, 2023

possibly related to #771

@He-Pin
Copy link
Member

He-Pin commented Jan 29, 2024

link : #929

@He-Pin He-Pin added build sbt or build of the project help wanted Extra attention is needed labels Jan 29, 2024
@Roiocam
Copy link
Member

Roiocam commented Jul 18, 2024

@Roiocam
Copy link
Member

Roiocam commented Jul 22, 2024

Because sometimes the actor don't put value into MDC:

LoggingEvent(
		INFO,
		org.apache.pekko.cluster.typed.ClusterActorLoggingSpec,
		ClusterActorLoggingSpec-pekko.actor.default-dispatcher-11,
		Starting,
		1721630292397,
		None,	
		None,
+		Map(pekkoAddress -> pekko.tcp://[email protected]:42905, pekkoSource -> pekko://ClusterActorLoggingSpec/user/$a, sourceActorSystem -> ClusterActorLoggingSpec)
)
LoggingEvent(
		INFO,
		org.apache.pekko.cluster.typed.ClusterActorLoggingSpec,
		ClusterActorLoggingSpec-pekko.actor.default-dispatcher-3,
		Starting,
		1721631006935,
		None,
		None,
-		Map()
)

@raboof
Copy link
Member

raboof commented Jul 22, 2024

Because sometimes the actor don't put value into MDC

Doesn't that mean the test caught a bug?

@Roiocam
Copy link
Member

Roiocam commented Jul 23, 2024

Doesn't that mean the test caught a bug?

It is flaky depending on how fast SLF4J initialization.

If it loads slower, it will use SubstituteLogger(which uses BasicMDCAdapter) as a fallback.

截屏2024-07-23 09 32 21

if we use MDC earlier than SLF4J initialization, the MDCAdapter may no chance to update it.

image

截屏2024-07-23 09 24 52

@Roiocam
Copy link
Member

Roiocam commented Jul 24, 2024

won't reopen it because ci is passing: https://github.com/apache/pekko/actions/runs/10076913173/job/27858277926

@Roiocam Roiocam self-assigned this Jul 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build sbt or build of the project help wanted Extra attention is needed
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants