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

Added Maven dependency example #57

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Conversation

clehene
Copy link

@clehene clehene commented Dec 3, 2018

No description provided.

@googlebot
Copy link
Collaborator

Thanks for your pull request. It looks like this may be your first contribution to a Google open source project (if not, look below for help). Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

📝 Please visit https://cla.developers.google.com/ to sign.

Once you've signed (or fixed any issues), please reply here (e.g. I signed it!) and we'll verify it.


What to do if you already signed the CLA

Individual signers
Corporate signers

@clehene
Copy link
Author

clehene commented Dec 3, 2018

I signed the CLA

@googlebot
Copy link
Collaborator

CLAs look good, thanks!

@googlebot googlebot added cla: yes and removed cla: no labels Dec 3, 2018
</dependency>
```

Optionally
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you please describe in what circumstances one would want to add the explicit dependency on log4j/exclusions? If I'm reading this directly, I don't know why/when I would do this instead of the first example above.

If the explanation is long enough, perhaps a footnote would help?

Copy link
Author

@clehene clehene Nov 5, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@nglorioso I don't know / remember. Flogger wasted more time than it saved to the point where we ended up debugging JUL in tears.

It manages to take something that typically causes problems (e.g. slf4j + X) and compounds that complexity into something more difficult. I'm not sure it's worth the trouble.

I may be too stupid / ignorant to actually figure it out. Currently have to do static blocks like

  static {
    System.setProperty("flogger.backend_factory", "com.google.common.flogger.backend.slf4j.Slf4jBackendFactory#getInstance");
  }

to get it working but for some reason this PR is still open...

Here's how the dependency management section looks like

      <dependency>
        <groupId>com.google.flogger</groupId>
        <artifactId>flogger</artifactId>
        <version>${google.flogger.version}</version>
      </dependency>
      <dependency>
        <groupId>com.google.flogger</groupId>
        <artifactId>flogger-system-backend</artifactId>
        <version>${google.flogger.version}</version>
        <scope>runtime</scope>
      </dependency>
      <dependency>
        <groupId>com.google.flogger</groupId>
        <artifactId>flogger-slf4j-backend</artifactId>
        <version>${google.flogger.version}</version>
      </dependency>
      <dependency>
        <groupId>org.slf4j</groupId>
        <artifactId>slf4j-api</artifactId>
        <version>${slf4j.version}</version>
      </dependency>
      <dependency>
        <groupId>ch.qos.logback</groupId>
        <artifactId>logback-classic</artifactId>
        <version>${logback.version}</version>
      </dependency>
      <dependency>
        <groupId>ch.qos.logback</groupId>
        <artifactId>logback-core</artifactId>
        <version>${logback.version}</version>
      </dependency>

<artifactId>flogger</artifactId>
<version>${flogger.version}</version>
</dependency>
<dependency>
Copy link
Member

@nick-someone nick-someone Nov 5, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It might be helpful to move the NOTE from below to above the Maven subheading and add inline XML comments like:

<!-- only in root component of your application --> 

above flogger-log4j-backend

@cpovirk cpovirk added the P3 label Jan 13, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants