Skip to content

[Fix-10918] Close datasource when expire from guava cache#11120

Merged
ruanwenjun merged 3 commits intoapache:devfrom
ruanwenjun:dev_wenjun_patch10918
Jul 23, 2022
Merged

[Fix-10918] Close datasource when expire from guava cache#11120
ruanwenjun merged 3 commits intoapache:devfrom
ruanwenjun:dev_wenjun_patch10918

Conversation

@ruanwenjun
Copy link
Member

@ruanwenjun ruanwenjun commented Jul 23, 2022

Purpose of the pull request

If the

close #10918

Brief change log

  • Add remove listener for guava cache
  • Close Datasource when DataSourceClient close.
  • Remove extra datasource in HiveDataSourceClient

Verify this pull request

This pull request is code cleanup without any test coverage.

(or)

This pull request is already covered by existing tests, such as (please describe tests).

(or)

This change added tests and can be verified as follows:

@ruanwenjun ruanwenjun force-pushed the dev_wenjun_patch10918 branch from 518f401 to 6d10d6c Compare July 23, 2022 08:54
@SbloodyS SbloodyS added the bug Something isn't working label Jul 23, 2022
Copy link
Member

@SbloodyS SbloodyS left a comment

Choose a reason for hiding this comment

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

LGTM

@codecov-commenter
Copy link

codecov-commenter commented Jul 23, 2022

Codecov Report

Merging #11120 (9346fda) into dev (952aee8) will decrease coverage by 0.00%.
The diff coverage is 0.00%.

@@             Coverage Diff              @@
##                dev   #11120      +/-   ##
============================================
- Coverage     40.35%   40.34%   -0.01%     
+ Complexity     4874     4872       -2     
============================================
  Files           950      950              
  Lines         37184    37187       +3     
  Branches       4077     4079       +2     
============================================
- Hits          15005    15004       -1     
- Misses        20669    20673       +4     
  Partials       1510     1510              
Impacted Files Coverage Δ
.../datasource/api/client/CommonDataSourceClient.java 0.00% <0.00%> (ø)
...atasource/api/plugin/DataSourceClientProvider.java 0.00% <0.00%> (ø)
...r/plugin/datasource/hive/HiveDataSourceClient.java 1.36% <0.00%> (+0.03%) ⬆️
...r/plugin/task/sqoop/parameter/SqoopParameters.java 53.33% <0.00%> (-1.34%) ⬇️

Help us with your feedback. Take ten seconds to tell us how you rate us.

@sonarqubecloud
Copy link

SonarCloud Quality Gate failed.    Quality Gate failed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 1 Code Smell

0.0% 0.0% Coverage
0.0% 0.0% Duplication

@ruanwenjun ruanwenjun merged commit 71cf7e1 into apache:dev Jul 23, 2022
@ruanwenjun ruanwenjun deleted the dev_wenjun_patch10918 branch July 23, 2022 12:43
caishunfeng pushed a commit that referenced this pull request Jul 27, 2022
* Close datasource when expire from guava cache
* Remove duplicate datasource in HiveDataSourceClient
ruanwenjun added a commit to ruanwenjun/dolphinscheduler that referenced this pull request Aug 4, 2022
* Close datasource when expire from guava cache
* Remove duplicate datasource in HiveDataSourceClient

(cherry picked from commit 71cf7e1)
ruanwenjun added a commit to ruanwenjun/dolphinscheduler that referenced this pull request Aug 12, 2022
…) (apache#33)

* Close datasource when expire from guava cache
* Remove duplicate datasource in HiveDataSourceClient

(cherry picked from commit 71cf7e1)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backend bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug] [DataSource] MySQL Connection number increasing

3 participants