Skip to content

Conversation

@viirya
Copy link
Member

@viirya viirya commented Dec 21, 2021

What changes were proposed in this pull request?

This patch proposes to add LoggingSuite back and also does some other improvements. In summary:

  1. Add LoggingSuite back
  2. Refactor logging related change based on community suggestion, e.g. let SparkShellLoggingFilter inherit from AbstractFilter instead of Filter.
  3. Fix maven test failures for hive-thriftserver module and restore previous log level to reduce log size
  4. Fix K8S decommision integration tests which check log output
  5. A few places in code/doc which refer/mention log4j.properties

Why are the changes needed?

LoggingSuite was wrongly removed in previous PR. We should add it back. There are a few places we can also simplify the code. A few places in code which programmingly write out log4j properties files are also changed to log4j2 here.

Does this PR introduce any user-facing change?

No

How was this patch tested?

Pass all tests.

@github-actions github-actions bot added the CORE label Dec 21, 2021
@SparkQA
Copy link

SparkQA commented Dec 21, 2021

Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/50892/

@SparkQA
Copy link

SparkQA commented Dec 21, 2021

Kubernetes integration test status failure
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/50892/

@SparkQA

This comment has been minimized.

@SparkQA
Copy link

SparkQA commented Dec 21, 2021

Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/50896/

@SparkQA
Copy link

SparkQA commented Dec 21, 2021

Kubernetes integration test status failure
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/50896/

@SparkQA
Copy link

SparkQA commented Dec 21, 2021

Test build #146421 has finished for PR 34965 at commit 0ac57d6.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@SparkQA
Copy link

SparkQA commented Dec 21, 2021

Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/50908/

@SparkQA
Copy link

SparkQA commented Dec 21, 2021

Kubernetes integration test status failure
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/50908/

@SparkQA
Copy link

SparkQA commented Dec 21, 2021

Test build #146433 has finished for PR 34965 at commit 7067976.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@SparkQA

This comment has been minimized.

@viirya viirya force-pushed the log4j2_improvement branch from 3c058d6 to 452515e Compare December 21, 2021 18:11
@SparkQA
Copy link

SparkQA commented Dec 21, 2021

Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/50923/

@SparkQA
Copy link

SparkQA commented Dec 21, 2021

Kubernetes integration test status failure
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/50923/

@SparkQA
Copy link

SparkQA commented Dec 21, 2021

Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/50927/

@viirya viirya changed the title [SPARK-37700][CORE][TEST] Add LoggingSuite and some improvements [SPARK-37700][CORE][TEST][test-maven] Add LoggingSuite and some improvements Dec 21, 2021
@viirya
Copy link
Member Author

viirya commented Dec 21, 2021

retest this please

@SparkQA
Copy link

SparkQA commented Dec 21, 2021

Test build #146453 has started for PR 34965 at commit 452515e.

@SparkQA
Copy link

SparkQA commented Dec 21, 2021

Kubernetes integration test status failure
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/50927/

@SparkQA
Copy link

SparkQA commented Dec 21, 2021

Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/50928/

@SparkQA
Copy link

SparkQA commented Dec 21, 2021

Test build #146452 has finished for PR 34965 at commit 452515e.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@SparkQA
Copy link

SparkQA commented Dec 21, 2021

Kubernetes integration test status failure
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/50928/

@SparkQA
Copy link

SparkQA commented Dec 22, 2021

Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/50969/

@SparkQA
Copy link

SparkQA commented Dec 22, 2021

Kubernetes integration test status failure
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/50969/

@SparkQA
Copy link

SparkQA commented Dec 22, 2021

Test build #146488 has finished for PR 34965 at commit 8d79c65.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@viirya
Copy link
Member Author

viirya commented Dec 22, 2021

cc @dongjoon-hyun @JoshRosen @srowen

-Dspark.kubernetes.test.jvmImage=$JVM_IMAGE_NAME
-Dspark.kubernetes.test.pythonImage=$PYTHON_IMAGE_NAME
-Dspark.kubernetes.test.rImage=$R_IMAGE_NAME
-Dlog4j.logger.org.apache.spark=DEBUG
Copy link
Member Author

Choose a reason for hiding this comment

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

This seems not work with log4j 2.x. So for K8S decommission integration tests which check logs, I updated the test code to set up a log4j2.properties.


appender.console.filter.1.a.type = ThresholdFilter
appender.console.filter.1.a.level = info
appender.console.filter.1.a.level = warn
Copy link
Member Author

Choose a reason for hiding this comment

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

followed original log4j1 properties file.

appender.file.type = File
appender.file.name = File
appender.file.fileName = target/unit-tests.log
appender.file.fileName = target/integration-tests.log
Copy link
Member Author

Choose a reason for hiding this comment

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

I coped it wrongly in previous PR.

@SparkQA
Copy link

SparkQA commented Dec 22, 2021

Test build #146493 has finished for PR 34965 at commit bd5ef16.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@SparkQA
Copy link

SparkQA commented Dec 23, 2021

Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/50988/

@SparkQA
Copy link

SparkQA commented Dec 23, 2021

Kubernetes integration test status failure
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/50988/

@SparkQA
Copy link

SparkQA commented Dec 23, 2021

Test build #146512 has finished for PR 34965 at commit 371f27e.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

Copy link
Member

@srowen srowen left a comment

Choose a reason for hiding this comment

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

Looks good. This could be a follow-up on the main log4j 2.x JIRA, as some downstream may be looking for a clear place to find the log4j 2 changes, but not important

@viirya viirya changed the title [SPARK-37700][CORE][TEST] Add LoggingSuite and some improvements [SPARK-6305][CORE][TEST][FOLLOWUP] Add LoggingSuite and some improvements Dec 23, 2021
@viirya
Copy link
Member Author

viirya commented Dec 23, 2021

Thanks @srowen . Changed the PR title to a follow-up on the main log4j 2.x JIRA.

@SparkQA
Copy link

SparkQA commented Dec 23, 2021

Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/51011/

@SparkQA
Copy link

SparkQA commented Dec 23, 2021

Kubernetes integration test status failure
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/51011/

@SparkQA
Copy link

SparkQA commented Dec 23, 2021

Test build #146536 has finished for PR 34965 at commit 2c233c9.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@viirya
Copy link
Member Author

viirya commented Dec 23, 2021

Thanks for review. I will merge this tonight.

@viirya
Copy link
Member Author

viirya commented Dec 24, 2021

Merging to master.

@viirya viirya closed this in 7fd3619 Dec 24, 2021
HyukjinKwon pushed a commit that referenced this pull request Dec 24, 2021
### What changes were proposed in this pull request?

This reverts commit c0cedb1.

### Why are the changes needed?

#35011 changes log level and causes some tests that check log message failed.

Actually #34965 was merged not long ago which fixes logging issue for hive-thriftserver module that produces large log output.

### Does this PR introduce _any_ user-facing change?

No

### How was this patch tested?

Pass tests.

Closes #35014 from viirya/revert-SPARK-37733.

Authored-by: Liang-Chi Hsieh <[email protected]>
Signed-off-by: Hyukjin Kwon <[email protected]>
sumwale pushed a commit to TIBCOSoftware/snappy-spark that referenced this pull request Feb 9, 2022
…ents

This patch proposes to add `LoggingSuite` back and also does some other improvements. In summary:

1. Add `LoggingSuite` back
2. Refactor logging related change based on community suggestion, e.g. let `SparkShellLoggingFilter` inherit from `AbstractFilter` instead of `Filter`.
3. Fix maven test failures for hive-thriftserver module
4. Fix K8S decommision integration tests which check log output
5. A few places in code/doc which refer/mention log4j.properties

`LoggingSuite` was wrongly removed in previous PR. We should add it back. There are a few places we can also simplify the code. A few places in code which programmingly write out log4j properties files are also changed to log4j2 here.

No

Pass all tests.

Closes apache#34965 from viirya/log4j2_improvement.

Authored-by: Liang-Chi Hsieh <[email protected]>
Signed-off-by: Liang-Chi Hsieh <[email protected]>
kazuyukitanimura pushed a commit to kazuyukitanimura/spark that referenced this pull request Aug 10, 2022
…ents

This patch proposes to add `LoggingSuite` back and also does some other improvements. In summary:

1. Add `LoggingSuite` back
2. Refactor logging related change based on community suggestion, e.g. let `SparkShellLoggingFilter` inherit from `AbstractFilter` instead of `Filter`.
3. Fix maven test failures for hive-thriftserver module
4. Fix K8S decommision integration tests which check log output
5. A few places in code/doc which refer/mention log4j.properties

`LoggingSuite` was wrongly removed in previous PR. We should add it back. There are a few places we can also simplify the code. A few places in code which programmingly write out log4j properties files are also changed to log4j2 here.

No

Pass all tests.

Closes apache#34965 from viirya/log4j2_improvement.

Authored-by: Liang-Chi Hsieh <[email protected]>
Signed-off-by: Liang-Chi Hsieh <[email protected]>
asiunov pushed a commit to ascend-io/spark that referenced this pull request Aug 25, 2022
…ents

This patch proposes to add `LoggingSuite` back and also does some other improvements. In summary:

1. Add `LoggingSuite` back
2. Refactor logging related change based on community suggestion, e.g. let `SparkShellLoggingFilter` inherit from `AbstractFilter` instead of `Filter`.
3. Fix maven test failures for hive-thriftserver module
4. Fix K8S decommision integration tests which check log output
5. A few places in code/doc which refer/mention log4j.properties

`LoggingSuite` was wrongly removed in previous PR. We should add it back. There are a few places we can also simplify the code. A few places in code which programmingly write out log4j properties files are also changed to log4j2 here.

No

Pass all tests.

Closes apache#34965 from viirya/log4j2_improvement.

Authored-by: Liang-Chi Hsieh <[email protected]>
Signed-off-by: Liang-Chi Hsieh <[email protected]>

(cherry picked from commit 7fd3619)
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