[RELENG-151] multipatch job not working Created: 23/Jul/20  Updated: 23/Jul/20  Resolved: 23/Jul/20

Status: Resolved
Project: releng
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Bug Priority: High
Reporter: Jamo Luhrsen Assignee: Thanh Ha (zxiiro)
Resolution: Done Votes: 0
Labels: multipatch
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


 Description   

the multipatch job does not seem to be working as expected. Here is a gerrit
where I left the comment "multipatch-build:topic=mri-magnesium-sr2" which
triggered this job but the PATCHES_TO_BUILD parameter is not "topic=mri-magnesium-sr2"
as we'd expect so the job fails.

The workaround is to manually start the job and fill in that parameter, like I did
here

Not everyone can start jenkins jobs manually, so we should fix this if we want to
encourage others to eventually start doing this kind of work.
 



 Comments   
Comment by Thanh Ha (zxiiro) [ 23/Jul/20 ]

So according to the logs GERRIT_EVENT_COMMENT_TEXT comes in as "UGF0Y2ggU2V0IDE6CgptdWx0aXBhdGNoLWJ1aWxkOnRvcGljPW1yaS1tYWduZXNpdW0tc3Iy" which is a base64 encoded value for the comment:

Patch Set 1:

multipatch-build:topic=mri-magnesium-sr2

This is a configuration in Jenkins as can be seen here (https://stackoverflow.com/questions/49187081/jenkins-gerrit-trigger-plugin-gives-encoded-gerrit-change-commit-message-and-ger). Perhaps someone at LF was changing configuration for the Gerrit Trigger plugin accidently configured it to use base64 encoding.

So we have 2 routes to resolve this:

1) LF admin changes this setting back to plain text
2) We decode the base64 encoding in our scripts

I think option 1 would be faster and less complicated though.

Comment by Thanh Ha (zxiiro) [ 23/Jul/20 ]

After some more research with agrimberg on IRC it appears there is no global setting for this which means likely a new version of Gerrit Trigger plugin must have changed this default setting value to base64. We'll have to resolve this at the job config level in this case.

Comment by Luis Gomez [ 23/Jul/20 ]

But if this is true, this should impact any job passing keywords and nobody has said anything (yet). Or maybe this impacts when job is re-generated (e.g. we saw this when we merged a patch in a script used by the job), because I just tried recheck in a regular patch and it still works.

Comment by Thanh Ha (zxiiro) [ 23/Jul/20 ]

It impacts all jobs that are parsing Gerrit comments (most likely jjb-deploy job also hits this issue). I'm not sure how many jobs we have that are parsing so we'll have to wait until folks complain and report.

If you're just doing a simple "recheck" those jobs are fine because it's not parsing any comment string text in the job (other than for the keyword to trigger it). Jobs that pass paramenters like "jjb-deploy: some-job-name" are the ones affected.

Comment by Jamo Luhrsen [ 23/Jul/20 ]

good point ecelgp, I know a lot of people are using jjb-deploy and no complaints so wondering why
they didn't hit this bug?

Comment by Thanh Ha (zxiiro) [ 23/Jul/20 ]

Here's patch for global-jjb and I think covers all jobs that use this feature https://gerrit.linuxfoundation.org/infra/c/releng/global-jjb/+/64622

Comment by Thanh Ha (zxiiro) [ 23/Jul/20 ]

I tracked it down to https://review.opendev.org/#/c/731169/ upstream JJB where the gerrit trigger plugin was improved to support configuring this option. Previously to that the option was unconfigurable in JJB so it defaulted to whatever the plugin defaulted to. We just started seeing this issue on Monday after we merged the JJB upgrade patch.

I think we understand the problem now and how to fix it so we can move forward with this.

Comment by Thanh Ha (zxiiro) [ 23/Jul/20 ]

This final releng/builder patch https://git.opendaylight.org/gerrit/c/releng/builder/+/91597 should take care of the remaining jobs that parse the GERRIT_EVENT_COMMENT_TEXT.

Comment by Thanh Ha (zxiiro) [ 23/Jul/20 ]

Fixes proposed to all relevant projects as far as I can tell. Once patches are merged we should be okay.

Comment by Luis Gomez [ 23/Jul/20 ]

OK, makes sense all your comments. Thanks zxiiro for fixing so fast

Generated at Wed Feb 07 20:37:37 UTC 2024 using Jira 8.20.10#820010-sha1:ace47f9899e9ee25d7157d59aa17ab06aee30d3d.