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

add job_id to gc task api #19073

Closed
wants to merge 1 commit into from

Conversation

lengrongfu
Copy link
Contributor

Thank you for contributing to Harbor!

Comprehensive Summary of your change

background:
When I view the gc job log from the ui, because my log has a lot of content, the loading is very slow, and I cannot view it in real time; therefore, I want to enter the jobserver pod to view the gc job log, but the log file is named after the job_id. I can't get job_id from ui.

solution:
In order to solve the problem of viewing the gc job, I think that the job_id can be output to the log file, so that the job_id can be viewed from the ui.

Issue being fixed

Fixes #(issue) #18999

Please indicate you've done the following:

  • Well Written Title and Summary of the PR
  • Label the PR as needed. "release-note/ignore-for-release, release-note/new-feature, release-note/update, release-note/enhancement, release-note/community, release-note/breaking-change, release-note/docs, release-note/infra, release-note/deprecation"
  • Accepted the DCO. Commits without the DCO will delay acceptance.
  • Made sure tests are passing and test coverage is added if needed.
  • Considered the docs impact and opened a new docs issue or PR with docs changes if needed in website repository.

@lengrongfu lengrongfu requested a review from a team as a code owner August 1, 2023 10:56
@codecov
Copy link

codecov bot commented Aug 1, 2023

Codecov Report

Merging #19073 (2bc9450) into main (bd34ad5) will increase coverage by 3.16%.
The diff coverage is 0.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main   #19073      +/-   ##
==========================================
+ Coverage   67.39%   70.56%   +3.16%     
==========================================
  Files         992      748     -244     
  Lines      108791    95427   -13364     
  Branches     2751        0    -2751     
==========================================
- Hits        73325    67342    -5983     
+ Misses      31528    24450    -7078     
+ Partials     3938     3635     -303     
Flag Coverage Δ
unittests 70.56% <0.00%> (+3.16%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Changed Coverage Δ
src/server/v2.0/handler/gc.go 2.19% <0.00%> (-0.22%) ⬇️
src/server/v2.0/handler/model/gc.go 0.00% <0.00%> (ø)
src/server/v2.0/handler/model/jobservice.go 0.00% <0.00%> (ø)
src/server/v2.0/handler/purge.go 9.54% <0.00%> (-0.38%) ⬇️

... and 251 files with indirect coverage changes

@chlins
Copy link
Member

chlins commented Aug 8, 2023

@lengrongfu Could you also help to go through other jobs API? We would like to keep the consistent for exposing the job id to the all tasks API.

Signed-off-by: lengrongfu <[email protected]>
@lengrongfu
Copy link
Contributor Author

@lengrongfu Could you also help to go through other jobs API? We would like to keep the consistent for exposing the job id to the all tasks API.

It has been added, please let me know if there is anything missing.

@github-actions
Copy link

github-actions bot commented Oct 8, 2023

This PR is being marked stale due to a period of inactivty. If this PR is still relevant, please comment or remove the stale label. Otherwise, this PR will close in 30 days.

@github-actions github-actions bot added the Stale label Oct 8, 2023
Copy link

github-actions bot commented Nov 7, 2023

This PR was closed because it has been stalled for 30 days with no activity. If this PR is still relevant, please re-open a new PR against main.

@github-actions github-actions bot closed this Nov 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants