Skip to content

feat: ApplicationSet controller sharding (#9002)#9568

Closed
hcelaloner wants to merge 1 commit intoargoproj:masterfrom
hcelaloner:feat/9002-implement-sharding-on-applicationset-controller
Closed

feat: ApplicationSet controller sharding (#9002)#9568
hcelaloner wants to merge 1 commit intoargoproj:masterfrom
hcelaloner:feat/9002-implement-sharding-on-applicationset-controller

Conversation

@hcelaloner
Copy link
Contributor

Fixes #9002
Co-authored-by: Erkan Zileli erkan.zileli@trendyol.com
Co-authored-by: Doğukan Tuna dogukan.tuna@trendyol.com
Signed-off-by: Celal Öner celal.oner@trendyol.com

Note on DCO:

If the DCO action in the integration test fails, one or more of your commits are not signed off. Please click on the Details link next to the DCO action for instructions on how to resolve this.

Checklist:

  • Either (a) I've created an enhancement proposal and discussed it with the community, (b) this is a bug fix, or (c) this does not need to be in the release notes.
  • The title of the PR states what changed and the related issues number (used for the release note).
  • I've included "Closes [ISSUE #]" or "Fixes [ISSUE #]" in the description to automatically close the associated issue.
  • I've updated both the CLI and UI to expose my feature, or I plan to submit a second PR with them.
  • Does this PR require documentation updates?
  • I've updated documentation as required by this PR.
  • Optional. My organization is added to USERS.md.
  • I have signed off all my commits as required by DCO
  • I have written unit and/or e2e tests for my change. PRs without these are unlikely to be merged.
  • My build is green (troubleshooting builds).

…er to applicationset controller

Fixes argoproj#9002
Co-authored-by: Erkan Zileli <erkan.zileli@trendyol.com>
Co-authored-by: Doğukan Tuna <dogukan.tuna@trendyol.com>
Signed-off-by: Celal Öner <celal.oner@trendyol.com>
@codecov
Copy link

codecov bot commented Jun 2, 2022

Codecov Report

Merging #9568 (8e8358d) into master (b2fe209) will increase coverage by 0.06%.
The diff coverage is 90.00%.

@@            Coverage Diff             @@
##           master    #9568      +/-   ##
==========================================
+ Coverage   45.77%   45.84%   +0.06%     
==========================================
  Files         222      223       +1     
  Lines       26372    26412      +40     
==========================================
+ Hits        12072    12108      +36     
- Misses      12651    12654       +3     
- Partials     1649     1650       +1     
Impacted Files Coverage Δ
...cationset/controllers/applicationset_controller.go 56.68% <50.00%> (-0.08%) ⬇️
applicationset/controllers/sharding/sharding.go 94.44% <94.44%> (ø)
util/settings/settings.go 48.16% <0.00%> (ø)

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 b2fe209...8e8358d. Read the comment docs.

} else {
h := fnv.New32a()
_, _ = h.Write([]byte(id))
return int(h.Sum32() % uint32(replicas))

Check failure

Code scanning / CodeQL

Incorrect conversion between integer types

Incorrect conversion of an integer with architecture-dependent bit size from [strconv.Atoi](1) to a lower bit size type uint32 without an upper bound check.
@crenshaw-dev crenshaw-dev changed the title feat: implement sharding mechanism used for argo application controller. Fixes #9002 feat: ApplicationSet controller sharding (#9002) Jun 2, 2022
@hcelaloner
Copy link
Contributor Author

Hi, we tried to provide an initial implementation for sharding based on ArgoCD's existing implementation. However, I guess it is not completed, we may need to convert deployment to statefulset as in ArgoCD application controller. If this feature is ok for you guys, can you guide us about missing parts or any preferred approaches on the codebase. We are using appsets heavily (~2k appsets ~8k apps) and facing some scalability issue, we would like to contribute as much as we can.

@rishabh625
Copy link
Member

Hey @hcelaloner , I would request you to create proposal and discuss it before doing any architectural changes

@hcelaloner
Copy link
Contributor Author

Hey @hcelaloner , I would request you to create proposal and discuss it before doing any architectural changes

@rishabh625 could you give me an example to understand the expectation from the proposal? In #9002, I tried to propose this as a solution but it was a one-sentence, I can try to give some details on the idea in that issue.

@rishabh625
Copy link
Member

Hey @hcelaloner , I would request you to create proposal and discuss it before doing any architectural changes

@rishabh625 could you give me an example to understand the expectation from the proposal? In #9002, I tried to propose this as a solution but it was a one-sentence, I can try to give some details on the idea in that issue.

I meant enhancement propsal , probably you could add more of your thinking in #9002 or here itself, i m good for now

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.

Performance of ApplicationSet Controller

2 participants