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

Define piped pluggin api #4815

Merged
merged 1 commit into from
Mar 11, 2024
Merged

Define piped pluggin api #4815

merged 1 commit into from
Mar 11, 2024

Conversation

khanhtc1202
Copy link
Member

@khanhtc1202 khanhtc1202 commented Mar 11, 2024

What this PR does / why we need it:

Add code base for pipedv1 at pkg/app/pipedv1, to test run of pipedv1, using this command locally

$ make run/piped CONFIG_FILE=.dev/piped-config.yaml EXPERIMENTAL=true

Also add a simple interface for pipedv1 plugging API. We will update it later

Which issue(s) this PR fixes:

Fixes #

Does this PR introduce a user-facing change?:

  • How are users affected by this change:
  • Is this breaking change:
  • How to migrate (if breaking change):

Signed-off-by: khanhtc1202 <[email protected]>
Copy link

codecov bot commented Mar 11, 2024

Codecov Report

Attention: Patch coverage is 25.90504% with 4073 lines in your changes are missing coverage. Please review.

Project coverage is 28.94%. Comparing base (51a49f9) to head (7e9a81c).

Files Patch % Lines
pkg/app/pipedv1/cmd/piped/piped.go 1.51% 648 Missing ⚠️
pkg/app/pipedv1/eventwatcher/eventwatcher.go 10.90% 481 Missing and 9 partials ⚠️
.../app/pipedv1/executor/analysis/metrics_analyzer.go 19.87% 256 Missing and 6 partials ⚠️
pkg/app/pipedv1/executor/analysis/analysis.go 0.00% 252 Missing ⚠️
pkg/app/pipedv1/executor/lambda/lambda.go 17.00% 242 Missing and 7 partials ⚠️
pkg/app/pipedv1/executor/kubernetes/traffic.go 24.84% 242 Missing and 6 partials ⚠️
pkg/app/pipedv1/executor/kubernetes/kubernetes.go 58.59% 192 Missing and 32 partials ⚠️
...app/pipedv1/appconfigreporter/appconfigreporter.go 31.15% 164 Missing and 15 partials ⚠️
pkg/app/pipedv1/executor/cloudrun/cloudrun.go 6.77% 163 Missing and 2 partials ⚠️
pkg/app/pipedv1/executor/kubernetes/rollback.go 0.00% 156 Missing ⚠️
... and 18 more
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #4815      +/-   ##
==========================================
- Coverage   30.62%   28.94%   -1.68%     
==========================================
  Files         227      317      +90     
  Lines       27207    40333   +13126     
==========================================
+ Hits         8331    11674    +3343     
- Misses      18216    27731    +9515     
- Partials      660      928     +268     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@khanhtc1202 khanhtc1202 enabled auto-merge (squash) March 11, 2024 07:53
@khanhtc1202 khanhtc1202 merged commit 5efd4cd into master Mar 11, 2024
19 of 21 checks passed
@khanhtc1202 khanhtc1202 deleted the define-piped-pluggin-api branch March 11, 2024 07:56
@github-actions github-actions bot mentioned this pull request Apr 8, 2024
t-kikuc pushed a commit that referenced this pull request Apr 8, 2024
t-kikuc pushed a commit that referenced this pull request Apr 8, 2024
t-kikuc added a commit that referenced this pull request Apr 8, 2024
* BUGFIX: Added cancel method to fix context leak (#4767)

Signed-off-by: fazledyn-or <[email protected]>

* Define piped pluggin api (#4815)

Signed-off-by: khanhtc1202 <[email protected]>

* Update BuldPlan API for piped pluggin (#4821)

Signed-off-by: khanhtc1202 <[email protected]>

* Relocate plugin proto (#4826)

Signed-off-by: khanhtc1202 <[email protected]>

* Update controller to use new planner logic (#4825)

* Update controller to use new planner logic

Signed-off-by: khanhtc1202 <[email protected]>

* Update proto path

Signed-off-by: khanhtc1202 <[email protected]>

* Fix typo

Signed-off-by: khanhtc1202 <[email protected]>

* Fix typo

Signed-off-by: khanhtc1202 <[email protected]>

* Update planner logic to call proto instead of self executing

Signed-off-by: khanhtc1202 <[email protected]>

---------

Signed-off-by: khanhtc1202 <[email protected]>

* Update plugin proto for ExecutorService and add piped pluginservice (#4834)

* Add plugin planner for k8s (#4819)

* [WIP] Add planner

Signed-off-by: Yoshiki Fujikane <[email protected]>

* Not to use out.Version

Signed-off-by: Yoshiki Fujikane <[email protected]>

* Use last_successful_commit_hash and last_successful_config_file_name

Signed-off-by: Yoshiki Fujikane <[email protected]>

* Use in.WorkingDir

Signed-off-by: Yoshiki Fujikane <[email protected]>

* Use in.PipedConfig

Signed-off-by: Yoshiki Fujikane <[email protected]>

* Create git client

Signed-off-by: Yoshiki Fujikane <[email protected]>

* Create secret encryptor

Signed-off-by: Yoshiki Fujikane <[email protected]>

* Add startup server implementation

Signed-off-by: Yoshiki Fujikane <[email protected]>

* Fix for relocation of proto api

Signed-off-by: Yoshiki Fujikane <[email protected]>

* Add roughly implementation for planner plugin

Signed-off-by: Yoshiki Fujikane <[email protected]>

* Rename pkg name

Signed-off-by: Yoshiki Fujikane <[email protected]>

* Add licence

Signed-off-by: Yoshiki Fujikane <[email protected]>

* Comment out for the testing code

Signed-off-by: Yoshiki Fujikane <[email protected]>

---------

Signed-off-by: Yoshiki Fujikane <[email protected]>

* Truncate `deploymentStatus` metrics after reporting stats (#4857)

* Truncate deploymentStatus metrics after reporting to avoid excess message size

Signed-off-by: t-kikuc <[email protected]>

* Rename func to Flush() for clarity

Signed-off-by: t-kikuc <[email protected]>

* Add comment of what's included in statsreporter's body

Signed-off-by: t-kikuc <[email protected]>

* Fix indent in the comment

Signed-off-by: t-kikuc <[email protected]>

* Copy change of metrics.go to pipedv1

Signed-off-by: t-kikuc <[email protected]>

* Copy change of reporter.go to pipedv1

Signed-off-by: t-kikuc <[email protected]>

---------

Signed-off-by: t-kikuc <[email protected]>

---------

Signed-off-by: fazledyn-or <[email protected]>
Signed-off-by: khanhtc1202 <[email protected]>
Signed-off-by: Yoshiki Fujikane <[email protected]>
Signed-off-by: t-kikuc <[email protected]>
Co-authored-by: Ataf Fazledin Ahamed <[email protected]>
Co-authored-by: Khanh Tran <[email protected]>
Co-authored-by: Yoshiki Fujikane <[email protected]>
@t-kikuc t-kikuc mentioned this pull request Apr 9, 2024
sZma5a pushed a commit to sZma5a/pipecd that referenced this pull request Apr 18, 2024
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.

3 participants