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

Optimize the memory usage #916

Merged
merged 6 commits into from
Dec 18, 2020
Merged

Optimize the memory usage #916

merged 6 commits into from
Dec 18, 2020

Conversation

cvictory
Copy link
Contributor

@cvictory cvictory commented Dec 9, 2020

What this PR does:

Optimize some memory usage issue , please refer to #901
In this way, we can remove some lock for it is cloned in MergeURL

Which issue(s) this PR fixes:

Fixes #901

Special notes for your reviewer:

Does this PR introduce a user-facing change?:

@codecov-io
Copy link

codecov-io commented Dec 9, 2020

Codecov Report

Merging #916 (29e6cff) into develop (25ed35d) will decrease coverage by 0.03%.
The diff coverage is 75.00%.

Impacted file tree graph

@@             Coverage Diff             @@
##           develop     #916      +/-   ##
===========================================
- Coverage    59.85%   59.82%   -0.04%     
===========================================
  Files          260      260              
  Lines        12854    12858       +4     
===========================================
- Hits          7694     7692       -2     
- Misses        4199     4202       +3     
- Partials       961      964       +3     
Impacted Files Coverage Δ
common/url.go 57.46% <75.00%> (+0.86%) ⬆️
cluster/router/chain/chain.go 59.34% <0.00%> (-4.07%) ⬇️
remoting/kubernetes/client.go 72.72% <0.00%> (-3.04%) ⬇️
remoting/kubernetes/watch.go 77.17% <0.00%> (-2.18%) ⬇️
remoting/kubernetes/listener.go 50.52% <0.00%> (ø)
remoting/getty/pool.go 69.60% <0.00%> (+0.88%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 25ed35d...08a13cf. Read the comment docs.

common/url.go Outdated
@@ -427,6 +427,17 @@ func (c *URL) SetParam(key string, value string) {
c.params.Set(key, value)
}

// SetParams will replace the URL.params
// SetParams will put all key-value pair into url.
Copy link
Contributor

Choose a reason for hiding this comment

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

This comment and function not match?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done

@LaurenceLiZhixin
Copy link
Contributor

LGTM

@cvictory cvictory merged commit ce90b4b into apache:develop Dec 18, 2020
AlexStocks pushed a commit that referenced this pull request Apr 14, 2021
* #901 Optimize the memory usage.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants