Skip to content

refactor: fuse sidecar serverless platform#4816

Merged
cheyang merged 10 commits intofluid-cloudnative:masterfrom
TrafalgarZZZ:refactor/fuse_sidecar_serverless_platform
Mar 26, 2025
Merged

refactor: fuse sidecar serverless platform#4816
cheyang merged 10 commits intofluid-cloudnative:masterfrom
TrafalgarZZZ:refactor/fuse_sidecar_serverless_platform

Conversation

@TrafalgarZZZ
Copy link
Copy Markdown
Member

@TrafalgarZZZ TrafalgarZZZ commented Mar 24, 2025

Ⅰ. Describe what this PR does

Currently, Fluid webhook gets serverless platform from a specific label in Pod's metadata. The label's key is set by a env variable called KEY_SERVERLESS_PLATFORM. This is not a great design because each time when we add a new serverless platform, we also need to change the Webhook's MutatingWebhookConfiguration to register the webhook with a matched objectSelector. This makes MutatingWebhookConfiguration longer.

This PR refactors the logic about getting serverless platform. Fluid webhook now looks at the Pod's annotation to see if there's an special annotation called serverless.fluid.io/platform.

Other changes this PR made:

  • clean and refactor some unused code
  • deprecate ServerlessPlatformKey which is defined from a env variable.

Ⅱ. Does this pull request fix one issue?

NONE

Ⅲ. List the added test cases (unit test/integration test) if any, please explain if no tests are needed.

Ⅳ. Describe how to verify it

Ⅴ. Special notes for reviews

@fluid-e2e-bot
Copy link
Copy Markdown

fluid-e2e-bot Bot commented Mar 24, 2025

Skipping CI for Draft Pull Request.
If you want CI signal for your change, please convert it to an actual PR.
You can still manually trigger a test run with /test all

@TrafalgarZZZ TrafalgarZZZ marked this pull request as ready for review March 25, 2025 07:09
…atform

Signed-off-by: trafalgarzzz <trafalgarz@outlook.com>
…ction

Signed-off-by: trafalgarzzz <trafalgarz@outlook.com>
Signed-off-by: trafalgarzzz <trafalgarz@outlook.com>
Signed-off-by: trafalgarzzz <trafalgarz@outlook.com>
Signed-off-by: trafalgarzzz <trafalgarz@outlook.com>
Signed-off-by: trafalgarzzz <trafalgarz@outlook.com>
Signed-off-by: trafalgarzzz <trafalgarz@outlook.com>
Signed-off-by: trafalgarzzz <trafalgarz@outlook.com>
@TrafalgarZZZ TrafalgarZZZ force-pushed the refactor/fuse_sidecar_serverless_platform branch from eba7b49 to f8b3f80 Compare March 25, 2025 07:33
@TrafalgarZZZ
Copy link
Copy Markdown
Member Author

/hold

1 similar comment
@TrafalgarZZZ
Copy link
Copy Markdown
Member Author

/hold

Signed-off-by: trafalgarzzz <trafalgarz@outlook.com>
@TrafalgarZZZ
Copy link
Copy Markdown
Member Author

/test fluid-e2e

@TrafalgarZZZ
Copy link
Copy Markdown
Member Author

/unhold

Comment thread pkg/utils/annotations.go Outdated
@cheyang
Copy link
Copy Markdown
Collaborator

cheyang commented Mar 26, 2025

Thank you for your great work. Please add developer doc in future PR.

Signed-off-by: trafalgarzzz <trafalgarz@outlook.com>
@sonarqubecloud
Copy link
Copy Markdown

Copy link
Copy Markdown
Collaborator

@cheyang cheyang left a comment

Choose a reason for hiding this comment

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

/lgtm
/approve

@fluid-e2e-bot
Copy link
Copy Markdown

fluid-e2e-bot Bot commented Mar 26, 2025

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: cheyang

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@cheyang cheyang merged commit 56b744d into fluid-cloudnative:master Mar 26, 2025
14 checks passed
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.

2 participants