Skip to content

Use Airlift logger#260

Merged
ebyhr merged 1 commit intotrinodb:mainfrom
ebyhr:ebi/airlift-log
Mar 7, 2024
Merged

Use Airlift logger#260
ebyhr merged 1 commit intotrinodb:mainfrom
ebyhr:ebi/airlift-log

Conversation

@ebyhr
Copy link
Copy Markdown
Member

@ebyhr ebyhr commented Feb 17, 2024

Fixes #147

@cla-bot cla-bot Bot added the cla-signed label Feb 17, 2024
@ebyhr ebyhr marked this pull request as draft February 17, 2024 04:06
@mosabua
Copy link
Copy Markdown
Member

mosabua commented Feb 21, 2024

I like this approach. Not a review .. just an initial thought:

We should we add docs on how to configure logging and add minimal config to jar with dependencies and docker container.

@ebyhr ebyhr marked this pull request as ready for review February 29, 2024 13:05
@ebyhr ebyhr requested a review from wendigo February 29, 2024 13:06
Comment thread docs/installation.md Outdated

### Configure logging

Path to `log.properties` needs to be set via `log.levels-file` JVM options
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

This should be added to release notes as a breaking change

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Also we need to explain what to configure in log.properties
separate lines of

javapackage=level

and what available levels are. In fact this should also be done better in the Trino docs btw

Comment thread gateway-ha/src/main/java/io/trino/gateway/baseapp/BaseApp.java
Comment thread gateway-ha/src/main/java/io/trino/gateway/ha/notifier/EmailNotifier.java Outdated
Comment thread gateway-ha/src/main/java/io/trino/gateway/ha/resource/TrinoResource.java Outdated
Comment thread gateway-ha/src/main/java/io/trino/gateway/ha/resource/TrinoResource.java Outdated
Comment thread gateway-ha/src/main/java/io/trino/gateway/ha/resource/TrinoResource.java Outdated
Comment thread gateway-ha/src/main/java/io/trino/gateway/proxyserver/ProxyServletImpl.java Outdated
@ebyhr
Copy link
Copy Markdown
Member Author

ebyhr commented Mar 6, 2024

Rebased on main without any changes.

Copy link
Copy Markdown
Member

@mosabua mosabua left a comment

Choose a reason for hiding this comment

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

Some minor questions mostly .. but essentially good to go.

Comment thread docs/installation.md Outdated

### Configure logging

Path to `log.properties` needs to be set via `log.levels-file` JVM options
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Suggested change
Path to `log.properties` needs to be set via `log.levels-file` JVM options
Path to `log.properties` must be set via `log.levels-file` JVM options

Comment thread docs/installation.md Outdated
Path to `log.properties` needs to be set via `log.levels-file` JVM options
like `-Dlog.levels-file=etc/log.properties`.

Find more information in the [logging properties](https://trino.io/docs/current/admin/properties-logging.html)
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Suggested change
Find more information in the [logging properties](https://trino.io/docs/current/admin/properties-logging.html)
Use the `log.*` properties from the [Trino logging properties documentation](https://trino.io/docs/current/admin/properties-logging.html) for further configuration.

probably .. but .. those have to also be set as -D parameters... need to explain that.

Comment thread docs/installation.md Outdated

### Configure logging

Path to `log.properties` needs to be set via `log.levels-file` JVM options
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Also we need to explain what to configure in log.properties
separate lines of

javapackage=level

and what available levels are. In fact this should also be done better in the Trino docs btw

Comment thread gateway-ha/pom.xml
<dependency>
<groupId>io.dropwizard</groupId>
<artifactId>dropwizard-logging</artifactId>
<artifactId>dropwizard-request-logging</artifactId>
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

would be nice to get rid of this and just use jetty directly .. but for now it might have to stay

Comment thread gateway-ha/pom.xml
<version>2.1.1</version>
</dependency>

<dependency>
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I assume this is the suggested use from airlift/trino for the servlet api

@ebyhr ebyhr merged commit d22a32b into trinodb:main Mar 7, 2024
@ebyhr ebyhr deleted the ebi/airlift-log branch March 7, 2024 01:07
@github-actions github-actions Bot added this to the 7 milestone Mar 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Development

Successfully merging this pull request may close these issues.

Use INFO log level by default in tests

3 participants