pipe-cd / pipecd

The One CD for All {applications, platforms, operations}
https://pipecd.dev
Apache License 2.0
1.09k stars 153 forks source link

Introduce plugin logpersister package #5342

Closed khanhtc1202 closed 1 day ago

khanhtc1202 commented 1 day ago

What this PR does:

Introduce plugin logpsersister package

Why we need it:

In pipedv0, we use logPersister as the writer for stage logs (which will later be used to show stage logs on UI). In this PR, I created pkg/plugin/logpersister package, with the same responsibility, but instead of sending the stage log directly to the controlplane, it sends to piped plugin-api then piped will send it to the controlplane.

Which issue(s) this PR fixes:

Part of #4980

Does this PR introduce a user-facing change?:

codecov[bot] commented 1 day ago

Codecov Report

Attention: Patch coverage is 0% with 48 lines in your changes missing coverage. Please review.

Project coverage is 25.28%. Comparing base (519d3fc) to head (cb668cf). Report is 1 commits behind head on master.

Files with missing lines Patch % Lines
pkg/app/pipedv1/cmd/piped/grpcapi/plugin_api.go 0.00% 35 Missing :warning:
pkg/app/pipedv1/controller/controller.go 0.00% 6 Missing :warning:
pkg/app/pipedv1/controller/scheduler.go 0.00% 4 Missing :warning:
pkg/plugin/logpersister/persister.go 0.00% 2 Missing :warning:
pkg/app/pipedv1/cmd/piped/piped.go 0.00% 1 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #5342 +/- ## ========================================== - Coverage 25.29% 25.28% -0.02% ========================================== Files 444 444 Lines 47650 47656 +6 ========================================== - Hits 12055 12049 -6 - Misses 34652 34664 +12 Partials 943 943 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.