You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@impala.apache.org by "Quanlong Huang (Code Review)" <ge...@cloudera.org> on 2024/04/12 13:20:57 UTC
[Impala-ASF-CR] IMPALA-12999: Add log4j.properties to the DEB/RPM packages
Quanlong Huang has uploaded this change for review. ( http://gerrit.cloudera.org:8080/21293
Change subject: IMPALA-12999: Add log4j.properties to the DEB/RPM packages
......................................................................
IMPALA-12999: Add log4j.properties to the DEB/RPM packages
log4j.properties is required to configure log4j before logs from it are
redirected to glog (done in GlogAppender#Install()). This is crucial to
show error logs during initialization, especially while lauching the
JVM. See the JIRA description for an example.
This copies log4j.properties from fe/src/test/resources directly since
it hasn't changed for years.
Change-Id: Iee0b9699ef313aa8e94bd351fa51fad3ea0cdf57
---
A package/conf/log4j.properties
1 file changed, 28 insertions(+), 0 deletions(-)
git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/93/21293/1
--
To view, visit http://gerrit.cloudera.org:8080/21293
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: Iee0b9699ef313aa8e94bd351fa51fad3ea0cdf57
Gerrit-Change-Number: 21293
Gerrit-PatchSet: 1
Gerrit-Owner: Quanlong Huang <hu...@gmail.com>
[Impala-ASF-CR] IMPALA-12999: Add log4j.properties to the DEB/RPM packages
Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/21293 )
Change subject: IMPALA-12999: Add log4j.properties to the DEB/RPM packages
......................................................................
Patch Set 2: Verified+1
--
To view, visit http://gerrit.cloudera.org:8080/21293
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Iee0b9699ef313aa8e94bd351fa51fad3ea0cdf57
Gerrit-Change-Number: 21293
Gerrit-PatchSet: 2
Gerrit-Owner: Quanlong Huang <hu...@gmail.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Quanlong Huang <hu...@gmail.com>
Gerrit-Reviewer: Xiang Yang <yx...@126.com>
Gerrit-Reviewer: Zihao Ye <ey...@163.com>
Gerrit-Reviewer: Zoltan Borok-Nagy <bo...@cloudera.com>
Gerrit-Comment-Date: Sun, 14 Apr 2024 10:10:46 +0000
Gerrit-HasComments: No
[Impala-ASF-CR] IMPALA-12999: Add log4j.properties to the DEB/RPM packages
Posted by "Quanlong Huang (Code Review)" <ge...@cloudera.org>.
Quanlong Huang has posted comments on this change. ( http://gerrit.cloudera.org:8080/21293 )
Change subject: IMPALA-12999: Add log4j.properties to the DEB/RPM packages
......................................................................
Patch Set 1:
> Miraculously, I can see the stacktrace without the 'conf/log4j.properties' file.
Maybe log4j.properties from some jars is used. You can add the following codes to print it:
diff --git a/fe/src/main/java/org/apache/impala/util/GlogAppender.java b/fe/src/main/java/org/apache/impala/util/GlogAppender.java
index 82c6c79cf..9ed49e45b 100644
--- a/fe/src/main/java/org/apache/impala/util/GlogAppender.java
+++ b/fe/src/main/java/org/apache/impala/util/GlogAppender.java
@@ -115,6 +115,8 @@ public class GlogAppender extends AppenderSkeleton {
*/
public static void Install(TLogLevel impalaLogLevel, TLogLevel otherLogLevel)
throws InternalException {
+ System.out.println("log4j.xml: " + Logger.getRootLogger().getClass().getResource("/log4j.xml"));
+ System.out.println("log4j.properties: " + Logger.getRootLogger().getClass().getResource("/log4j.properties"));
Properties properties = new Properties();
properties.setProperty("log4j.appender.glog", GlogAppender.class.getName());
--
To view, visit http://gerrit.cloudera.org:8080/21293
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Iee0b9699ef313aa8e94bd351fa51fad3ea0cdf57
Gerrit-Change-Number: 21293
Gerrit-PatchSet: 1
Gerrit-Owner: Quanlong Huang <hu...@gmail.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Quanlong Huang <hu...@gmail.com>
Gerrit-Reviewer: Xiang Yang <yx...@126.com>
Gerrit-Reviewer: Zihao Ye <ey...@163.com>
Gerrit-Reviewer: Zoltan Borok-Nagy <bo...@cloudera.com>
Gerrit-Comment-Date: Sat, 13 Apr 2024 21:24:42 +0000
Gerrit-HasComments: No
[Impala-ASF-CR] IMPALA-12999: Add log4j.properties to the DEB/RPM packages
Posted by "Xiang Yang (Code Review)" <ge...@cloudera.org>.
Xiang Yang has posted comments on this change. ( http://gerrit.cloudera.org:8080/21293 )
Change subject: IMPALA-12999: Add log4j.properties to the DEB/RPM packages
......................................................................
Patch Set 1: Code-Review+1
Thanks quanlong.
Miraculously, I can see the stacktrace without the 'conf/log4j.properties' file.
--
To view, visit http://gerrit.cloudera.org:8080/21293
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Iee0b9699ef313aa8e94bd351fa51fad3ea0cdf57
Gerrit-Change-Number: 21293
Gerrit-PatchSet: 1
Gerrit-Owner: Quanlong Huang <hu...@gmail.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Quanlong Huang <hu...@gmail.com>
Gerrit-Reviewer: Xiang Yang <yx...@126.com>
Gerrit-Reviewer: Zihao Ye <ey...@163.com>
Gerrit-Reviewer: Zoltan Borok-Nagy <bo...@cloudera.com>
Gerrit-Comment-Date: Sat, 13 Apr 2024 03:51:29 +0000
Gerrit-HasComments: No
[Impala-ASF-CR] IMPALA-12999: Add log4j.properties to the DEB/RPM packages
Posted by "Quanlong Huang (Code Review)" <ge...@cloudera.org>.
Quanlong Huang has posted comments on this change. ( http://gerrit.cloudera.org:8080/21293 )
Change subject: IMPALA-12999: Add log4j.properties to the DEB/RPM packages
......................................................................
Patch Set 1:
Thanks for the review! Merging this.
--
To view, visit http://gerrit.cloudera.org:8080/21293
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Iee0b9699ef313aa8e94bd351fa51fad3ea0cdf57
Gerrit-Change-Number: 21293
Gerrit-PatchSet: 1
Gerrit-Owner: Quanlong Huang <hu...@gmail.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Quanlong Huang <hu...@gmail.com>
Gerrit-Reviewer: Xiang Yang <yx...@126.com>
Gerrit-Reviewer: Zihao Ye <ey...@163.com>
Gerrit-Reviewer: Zoltan Borok-Nagy <bo...@cloudera.com>
Gerrit-Comment-Date: Sun, 14 Apr 2024 05:07:05 +0000
Gerrit-HasComments: No
[Impala-ASF-CR] IMPALA-12999: Add log4j.properties to the DEB/RPM packages
Posted by "Zihao Ye (Code Review)" <ge...@cloudera.org>.
Zihao Ye has posted comments on this change. ( http://gerrit.cloudera.org:8080/21293 )
Change subject: IMPALA-12999: Add log4j.properties to the DEB/RPM packages
......................................................................
Patch Set 1: Code-Review+2
--
To view, visit http://gerrit.cloudera.org:8080/21293
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Iee0b9699ef313aa8e94bd351fa51fad3ea0cdf57
Gerrit-Change-Number: 21293
Gerrit-PatchSet: 1
Gerrit-Owner: Quanlong Huang <hu...@gmail.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Quanlong Huang <hu...@gmail.com>
Gerrit-Reviewer: Xiang Yang <yx...@126.com>
Gerrit-Reviewer: Zihao Ye <ey...@163.com>
Gerrit-Reviewer: Zoltan Borok-Nagy <bo...@cloudera.com>
Gerrit-Comment-Date: Sat, 13 Apr 2024 13:26:28 +0000
Gerrit-HasComments: No
[Impala-ASF-CR] IMPALA-12999: Add log4j.properties to the DEB/RPM packages
Posted by "Xiang Yang (Code Review)" <ge...@cloudera.org>.
Xiang Yang has posted comments on this change. ( http://gerrit.cloudera.org:8080/21293 )
Change subject: IMPALA-12999: Add log4j.properties to the DEB/RPM packages
......................................................................
Patch Set 1:
> Patch Set 1:
>
> > Miraculously, I can see the stacktrace without the 'conf/log4j.properties' file.
>
> Maybe log4j.properties from some jars is used. You can add the following codes to print it:
>
> diff --git a/fe/src/main/java/org/apache/impala/util/GlogAppender.java b/fe/src/main/java/org/apache/impala/util/GlogAppender.java
> index 82c6c79cf..9ed49e45b 100644
> --- a/fe/src/main/java/org/apache/impala/util/GlogAppender.java
> +++ b/fe/src/main/java/org/apache/impala/util/GlogAppender.java
> @@ -115,6 +115,8 @@ public class GlogAppender extends AppenderSkeleton {
> */
> public static void Install(TLogLevel impalaLogLevel, TLogLevel otherLogLevel)
> throws InternalException {
> + System.out.println("log4j.xml: " + Logger.getRootLogger().getClass().getResource("/log4j.xml"));
> + System.out.println("log4j.properties: " + Logger.getRootLogger().getClass().getResource("/log4j.properties"));
> Properties properties = new Properties();
> properties.setProperty("log4j.appender.glog", GlogAppender.class.getName());
Got it, I tested it in the dev env and the path 'fe/src/test/resources' was added in the CLASSPATH.
--
To view, visit http://gerrit.cloudera.org:8080/21293
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Iee0b9699ef313aa8e94bd351fa51fad3ea0cdf57
Gerrit-Change-Number: 21293
Gerrit-PatchSet: 1
Gerrit-Owner: Quanlong Huang <hu...@gmail.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Quanlong Huang <hu...@gmail.com>
Gerrit-Reviewer: Xiang Yang <yx...@126.com>
Gerrit-Reviewer: Zihao Ye <ey...@163.com>
Gerrit-Reviewer: Zoltan Borok-Nagy <bo...@cloudera.com>
Gerrit-Comment-Date: Sun, 14 Apr 2024 01:14:25 +0000
Gerrit-HasComments: No
[Impala-ASF-CR] IMPALA-12999: Add log4j.properties to the DEB/RPM packages
Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/21293 )
Change subject: IMPALA-12999: Add log4j.properties to the DEB/RPM packages
......................................................................
Patch Set 1:
Build Successful
https://jenkins.impala.io/job/gerrit-code-review-checks/15881/ : Initial code review checks passed. Use gerrit-verify-dryrun-external or gerrit-verify-dryrun to run full precommit tests.
--
To view, visit http://gerrit.cloudera.org:8080/21293
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Iee0b9699ef313aa8e94bd351fa51fad3ea0cdf57
Gerrit-Change-Number: 21293
Gerrit-PatchSet: 1
Gerrit-Owner: Quanlong Huang <hu...@gmail.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Fri, 12 Apr 2024 13:44:23 +0000
Gerrit-HasComments: No
[Impala-ASF-CR] IMPALA-12999: Add log4j.properties to the DEB/RPM packages
Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has submitted this change and it was merged. ( http://gerrit.cloudera.org:8080/21293 )
Change subject: IMPALA-12999: Add log4j.properties to the DEB/RPM packages
......................................................................
IMPALA-12999: Add log4j.properties to the DEB/RPM packages
log4j.properties is required to configure log4j before logs from it are
redirected to glog (done in GlogAppender#Install()). This is crucial to
show error logs during initialization, especially while lauching the
JVM. See the JIRA description for an example.
This copies log4j.properties from fe/src/test/resources directly since
it hasn't changed for years.
Change-Id: Iee0b9699ef313aa8e94bd351fa51fad3ea0cdf57
Reviewed-on: http://gerrit.cloudera.org:8080/21293
Reviewed-by: Impala Public Jenkins <im...@cloudera.com>
Tested-by: Impala Public Jenkins <im...@cloudera.com>
---
A package/conf/log4j.properties
1 file changed, 28 insertions(+), 0 deletions(-)
Approvals:
Impala Public Jenkins: Looks good to me, approved; Verified
--
To view, visit http://gerrit.cloudera.org:8080/21293
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: Iee0b9699ef313aa8e94bd351fa51fad3ea0cdf57
Gerrit-Change-Number: 21293
Gerrit-PatchSet: 3
Gerrit-Owner: Quanlong Huang <hu...@gmail.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Quanlong Huang <hu...@gmail.com>
Gerrit-Reviewer: Xiang Yang <yx...@126.com>
Gerrit-Reviewer: Zihao Ye <ey...@163.com>
Gerrit-Reviewer: Zoltan Borok-Nagy <bo...@cloudera.com>
[Impala-ASF-CR] IMPALA-12999: Add log4j.properties to the DEB/RPM packages
Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/21293 )
Change subject: IMPALA-12999: Add log4j.properties to the DEB/RPM packages
......................................................................
Patch Set 2:
Build started: https://jenkins.impala.io/job/gerrit-verify-dryrun/10540/ DRY_RUN=false
--
To view, visit http://gerrit.cloudera.org:8080/21293
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Iee0b9699ef313aa8e94bd351fa51fad3ea0cdf57
Gerrit-Change-Number: 21293
Gerrit-PatchSet: 2
Gerrit-Owner: Quanlong Huang <hu...@gmail.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Quanlong Huang <hu...@gmail.com>
Gerrit-Reviewer: Xiang Yang <yx...@126.com>
Gerrit-Reviewer: Zihao Ye <ey...@163.com>
Gerrit-Reviewer: Zoltan Borok-Nagy <bo...@cloudera.com>
Gerrit-Comment-Date: Sun, 14 Apr 2024 05:07:34 +0000
Gerrit-HasComments: No
[Impala-ASF-CR] IMPALA-12999: Add log4j.properties to the DEB/RPM packages
Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/21293 )
Change subject: IMPALA-12999: Add log4j.properties to the DEB/RPM packages
......................................................................
Patch Set 2: Code-Review+2
--
To view, visit http://gerrit.cloudera.org:8080/21293
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Iee0b9699ef313aa8e94bd351fa51fad3ea0cdf57
Gerrit-Change-Number: 21293
Gerrit-PatchSet: 2
Gerrit-Owner: Quanlong Huang <hu...@gmail.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Quanlong Huang <hu...@gmail.com>
Gerrit-Reviewer: Xiang Yang <yx...@126.com>
Gerrit-Reviewer: Zihao Ye <ey...@163.com>
Gerrit-Reviewer: Zoltan Borok-Nagy <bo...@cloudera.com>
Gerrit-Comment-Date: Sun, 14 Apr 2024 05:07:33 +0000
Gerrit-HasComments: No