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

ClassNotFoundException: com.google.common.flogger.backend.system.DefaultPlatform #55

Closed
clehene opened this issue Dec 2, 2018 · 5 comments

Comments

@clehene
Copy link

clehene commented Dec 2, 2018

jdk1.8.0_181.jdk
    <dependency>
      <groupId>com.google.flogger</groupId>
      <artifactId>flogger</artifactId>
      <version>0.3.1</version>
    </dependency>
Exception in thread "main" java.lang.ExceptionInInitializerError
	at com.google.common.flogger.backend.Platform.getCallerFinder(Platform.java:142)
	at com.google.common.flogger.FluentLogger.forEnclosingClass(FluentLogger.java:70)
	at io.tapwater.server.GrpcServer.<clinit>(GrpcServer.java:13)
Caused by: java.lang.IllegalStateException: No logging platforms found:
com.google.common.flogger.backend.system.DefaultPlatform: java.lang.ClassNotFoundException: com.google.common.flogger.backend.system.DefaultPlatform
	at com.google.common.flogger.backend.Platform$LazyHolder.loadFirstAvailablePlatform(Platform.java:99)
	at com.google.common.flogger.backend.Platform$LazyHolder.<clinit>(Platform.java:67)
	... 3 more
@clehene
Copy link
Author

clehene commented Dec 2, 2018

jar -tvf flogger-0.3.1.jar | grep Default
  4163 Fri Jan 01 00:00:02 PST 2010 com/google/common/flogger/parser/DefaultPrintfMessageParser.class
  2050 Fri Jan 01 00:00:02 PST 2010 com/google/common/flogger/parser/DefaultPrintfMessageParser$1.class
  1912 Fri Jan 01 00:00:02 PST 2010 com/google/common/flogger/parser/DefaultBraceStyleMessageParser.class

@ronshapiro
Copy link
Contributor

Are you able to create a Minimal, Complete, and Verifiable example that exhibits this behavior?

@clehene
Copy link
Author

clehene commented Dec 3, 2018

Hey @ronshapiro https://github.com/clehene/floggertest
Tried with both java 1.8.0_181 and 9.0.4 on OSX

@clehene
Copy link
Author

clehene commented Dec 3, 2018

@ronshapiro did you get a chance to look at that? I tried to figure it out myself but unfortunately the project doesn't build either and I wasn't able to figure out how to fix that either (#56).

I spent time to add it to the project, but now it's blocking me so I'll have to revert it for now.

@ronshapiro
Copy link
Contributor

ronshapiro commented Dec 3, 2018 via email

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

No branches or pull requests

2 participants