Skip to content

Conversation

jayfranco999
Copy link
Collaborator

@jayfranco999 jayfranco999 commented May 29, 2025

As per - jenkins-infra/helpdesk#2843 (comment)

publishBuildStatusReport will publish the build status report on reports.jenkins.io using pre-existing publishReports shared library script.

Once completed we can move on to the next phase of monitoring the reports.

Testing with jenkins-infra/docker-404#46

@jayfranco999 jayfranco999 requested a review from a team as a code owner May 29, 2025 13:12
@jayfranco999 jayfranco999 marked this pull request as draft May 29, 2025 13:12
Copy link
Contributor

@dduportal dduportal left a comment

Choose a reason for hiding this comment

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

Unit tests are missing :)

@jayfranco999 jayfranco999 force-pushed the publishBuildStatusReport branch from 0d6cc00 to c15fbe3 Compare June 17, 2025 12:18
@jayfranco999
Copy link
Collaborator Author

Update:

Added unit tests.

@jayfranco999
Copy link
Collaborator Author

jayfranco999 commented Jul 3, 2025

Update:

Added a dir block to execute az copy commands in context of current directory in the agent. The report was generated in the expected path

https://builds.reports.jenkins.io/build_status_reports/infra.ci.jenkins.io/docker-jobs/docker-404/PR-46/status.json

Code clean-up has been performed for the pipeline script and the test suite.

principal branch check will be uncommented once approved.

@jayfranco999 jayfranco999 marked this pull request as ready for review July 3, 2025 12:19
@jayfranco999 jayfranco999 requested a review from dduportal July 3, 2025 12:20
Copy link
Contributor

@dduportal dduportal left a comment

Choose a reason for hiding this comment

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

Thanks @jayfranco999 . The code still have many things to review: it works but it is really verbose for not a lot of values (LLM generated?) which adds a lot of complexity and instructions.

As a general rule of thumb: the less you do in Pipeline (e.g. Groovy), the safer we are.
You should always aim at running one sh step and build thing around it (such as the required withEnv() wrapping).

=> A good start would be to remove the utility function for parsing Date and time, adn group the sh into a single step.

Don't hesitate to use my suggestions as starters

@jayfranco999 jayfranco999 force-pushed the publishBuildStatusReport branch from 115de37 to feebfbf Compare July 15, 2025 11:13
Signed-off-by: jayfranco999 <[email protected]>
Signed-off-by: jayfranco999 <[email protected]>
Signed-off-by: jayfranco999 <[email protected]>
Signed-off-by: jayfranco999 <[email protected]>
Signed-off-by: jayfranco999 <[email protected]>
Signed-off-by: jayfranco999 <[email protected]>
Signed-off-by: jayfranco999 <[email protected]>
Signed-off-by: jayfranco999 <[email protected]>
Signed-off-by: jayfranco999 <[email protected]>
Signed-off-by: jayfranco999 <[email protected]>
Signed-off-by: jayfranco999 <[email protected]>
Signed-off-by: jayfranco999 <[email protected]>
Signed-off-by: jayfranco999 <[email protected]>
Signed-off-by: jayfranco999 <[email protected]>
Signed-off-by: jayfranco999 <[email protected]>
Signed-off-by: jayfranco999 <[email protected]>
Signed-off-by: jayfranco999 <[email protected]>
Signed-off-by: jayfranco999 <[email protected]>
Signed-off-by: jayfranco999 <[email protected]>
@jayfranco999 jayfranco999 requested a review from dduportal July 22, 2025 10:49
Comment on lines 38 to 40
sh '''
bash ${SCRIPT_PATH}
'''
Copy link
Contributor

Choose a reason for hiding this comment

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

You have to intercept failures and collect logs (archiveArtfiacts) with the same technique as in Good idea. However you also need to collect the logs if the sh step (otherwise you don't need to collect azcopy logs).

We accept the simplification of saying: "either it succeeds or it fails. IF it fails, collect and archive logs)

@dduportal
Copy link
Contributor

@Art39print please stop spamming us or you'll be blocked.

jayfranco999 and others added 3 commits July 23, 2025 23:06
Signed-off-by: jayfranco999 <[email protected]>
Co-authored-by: Damien Duportal <[email protected]>
Signed-off-by: jayfranco999 <[email protected]>
@jayfranco999 jayfranco999 requested a review from dduportal July 23, 2025 17:43
Signed-off-by: jayfranco999 <[email protected]>
Signed-off-by: jayfranco999 <[email protected]>
Signed-off-by: jayfranco999 <[email protected]>
Signed-off-by: jayfranco999 <[email protected]>
Signed-off-by: jayfranco999 <[email protected]>
Signed-off-by: jayfranco999 <[email protected]>
Signed-off-by: jayfranco999 <[email protected]>
Signed-off-by: jayfranco999 <[email protected]>
Signed-off-by: jayfranco999 <[email protected]>
Copy link
Contributor

@dduportal dduportal left a comment

Choose a reason for hiding this comment

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

LGTM! We tested all cases on jenkins-infra/docker-404 and it works as expected: https://builds.reports.jenkins.io/build_status_reports/infra.ci.jenkins.io/docker-jobs/docker-404/main/status.json

@dduportal dduportal merged commit e098551 into jenkins-infra:master Jul 30, 2025
3 checks passed
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.

3 participants