-
Bug
-
Resolution: Unresolved
-
Minor
-
Jenkins: 2.361.1
OS: Windows Server 2019 - 10.0
---
ace-editor:1.1
active-directory:2.26
antisamy-markup-formatter:2.7
apache-httpcomponents-client-4-api:4.5.13-138.v4e7d9a_7b_a_e61
authentication-tokens:1.4
bootstrap4-api:4.6.0-5
bootstrap5-api:5.2.0-3
bouncycastle-api:2.26
branch-api:2.1046.v0ca_37783ecc5
build-timeout:1.24
caffeine-api:2.9.3-65.v6a_47d0f4d1fe
checks-api:1.7.5
cloudbees-folder:6.758.vfd75d09eea_a_1
command-launcher:84.v4a_97f2027398
conditional-buildstep:1.4.2
credentials:1143.vb_e8b_b_ceee347
credentials-binding:523.vd859a_4b_122e6
dark-theme:245.vb_a_2b_b_010ea_96
display-url-api:2.3.6
durable-task:500.v8927d9fd99d8
echarts-api:5.3.3-1
email-ext:2.91
external-monitor-job:192.ve979ca_8b_3ccd
font-awesome-api:6.1.2-1
generic-webhook-trigger:1.84
git:4.11.5
git-changelog:3.23
git-client:3.11.2
git-parameter:0.9.17
git-server:99.va_0826a_b_cdfa_d
github:1.35.0
github-api:1.303-400.v35c2d8258028
github-branch-source:1694.vd46793a_c4a_57
github-oauth:0.39
gitlab-api:5.0.1-78.v47a_45b_9f78b_7
gitlab-branch-source:636.v55fd8144d335
gitlab-logo:1.0.5
gitlab-merge-request-jenkins:2.0.0
gitlab-plugin:1.5.35
handlebars:3.0.8
handy-uri-templates-2-api:2.1.8-22.v77d5b_75e6953
instance-identity:116.vf8f487400980
jackson2-api:2.13.3-285.vc03c0256d517
jakarta-activation-api:2.0.1-1
jakarta-mail-api:2.0.1-1
javadoc:226.v71211feb_e7e9
javax-activation-api:1.2.0-4
javax-mail-api:1.6.2-7
jaxb:2.3.6-1
jdk-tool:55.v1b_32b_6ca_f9ca
jersey2-api:2.37-1
jjwt-api:0.11.5-77.v646c772fddb_0
jquery:1.12.4-1
jquery-detached:1.2.1
jquery3-api:3.6.0-4
jsch:0.1.55.61.va_e9ee26616e7
junit:1119.1121.vc43d0fc45561
ldap:2.12
lockable-resources:2.16
log-parser:2.2
mailer:438.v02c7f0a_12fa_4
mapdb-api:1.0.9-28.vf251ce40855d
matrix-auth:3.1.5
matrix-project:785.v06b_7f47b_c631
maven-plugin:3.19
mina-sshd-api-common:2.8.0-36.v8e25ce90d4b_1
mina-sshd-api-core:2.8.0-36.v8e25ce90d4b_1
momentjs:1.1.1
msbuild:1.30
naginator:1.18.1
nunit:0.27
okhttp-api:4.9.3-108.v0feda04578cf
p4:1.13.0
pam-auth:1.10
parameterized-trigger:2.45
pipeline-build-step:2.18
pipeline-github-lib:38.v445716ea_edda_
pipeline-githubnotify-step:49.vf37bf92d2bc8
pipeline-graph-analysis:195.v5812d95a_a_2f9
pipeline-groovy-lib:612.v84da_9c54906d
pipeline-input-step:449.v77f0e8b_845c4
pipeline-milestone-step:101.vd572fef9d926
pipeline-model-api:2.2114.v2654ca_721309
pipeline-model-definition:2.2114.v2654ca_721309
pipeline-model-extensions:2.2114.v2654ca_721309
pipeline-rest-api:2.24
pipeline-stage-step:296.v5f6908f017a_5
pipeline-stage-tags-metadata:2.2114.v2654ca_721309
pipeline-stage-view:2.24
plain-credentials:139.ved2b_9cf7587b
plugin-util-api:2.17.0
popper-api:1.16.1-3
popper2-api:2.11.6-1
powershell:1.7
resource-disposer:0.20
run-condition:1.5
scm-api:621.vda_a_b_055e58f7
script-security:1175.v4b_d517d6db_f0
slack:616.v03b_1e98d13dd
snakeyaml-api:1.31-84.ve43da_fb_49d0b
ssh-credentials:305.v8f4381501156
sshd:3.249.v2dc2ea_416e33
structs:324.va_f5d6774f3a_d
theme-manager:1.5
throttle-concurrents:2.9
timestamper:1.19
token-macro:308.v4f2b_ed62b_b_16
trilead-api:1.67.vc3938a_35172f
variant:59.vf075fe829ccb
violation-comments-to-gitlab:2.55
windows-slaves:1.8.1
wix:1.12
workflow-aggregator:590.v6a_d052e5a_a_b_5
workflow-api:1192.v2d0deb_19d212
workflow-basic-steps:994.vd57e3ca_46d24
workflow-cps:2759.v87459c4eea_ca_
workflow-durable-task-step:1199.v02b_9244f8064
workflow-job:1232.v5a_4c994312f1
workflow-multibranch:716.vc692a_e52371b_
workflow-scm-step:400.v6b_89a_1317c9a_
workflow-step-api:639.v6eca_cd8c04a_a_
workflow-support:838.va_3a_087b_4055b
ws-cleanup:0.43Jenkins: 2.361.1 OS: Windows Server 2019 - 10.0 --- ace-editor:1.1 active-directory:2.26 antisamy-markup-formatter:2.7 apache-httpcomponents-client-4-api:4.5.13-138.v4e7d9a_7b_a_e61 authentication-tokens:1.4 bootstrap4-api:4.6.0-5 bootstrap5-api:5.2.0-3 bouncycastle-api:2.26 branch-api:2.1046.v0ca_37783ecc5 build-timeout:1.24 caffeine-api:2.9.3-65.v6a_47d0f4d1fe checks-api:1.7.5 cloudbees-folder:6.758.vfd75d09eea_a_1 command-launcher:84.v4a_97f2027398 conditional-buildstep:1.4.2 credentials:1143.vb_e8b_b_ceee347 credentials-binding:523.vd859a_4b_122e6 dark-theme:245.vb_a_2b_b_010ea_96 display-url-api:2.3.6 durable-task:500.v8927d9fd99d8 echarts-api:5.3.3-1 email-ext:2.91 external-monitor-job:192.ve979ca_8b_3ccd font-awesome-api:6.1.2-1 generic-webhook-trigger:1.84 git:4.11.5 git-changelog:3.23 git-client:3.11.2 git-parameter:0.9.17 git-server:99.va_0826a_b_cdfa_d github:1.35.0 github-api:1.303-400.v35c2d8258028 github-branch-source:1694.vd46793a_c4a_57 github-oauth:0.39 gitlab-api:5.0.1-78.v47a_45b_9f78b_7 gitlab-branch-source:636.v55fd8144d335 gitlab-logo:1.0.5 gitlab-merge-request-jenkins:2.0.0 gitlab-plugin:1.5.35 handlebars:3.0.8 handy-uri-templates-2-api:2.1.8-22.v77d5b_75e6953 instance-identity:116.vf8f487400980 jackson2-api:2.13.3-285.vc03c0256d517 jakarta-activation-api:2.0.1-1 jakarta-mail-api:2.0.1-1 javadoc:226.v71211feb_e7e9 javax-activation-api:1.2.0-4 javax-mail-api:1.6.2-7 jaxb:2.3.6-1 jdk-tool:55.v1b_32b_6ca_f9ca jersey2-api:2.37-1 jjwt-api:0.11.5-77.v646c772fddb_0 jquery:1.12.4-1 jquery-detached:1.2.1 jquery3-api:3.6.0-4 jsch:0.1.55.61.va_e9ee26616e7 junit:1119.1121.vc43d0fc45561 ldap:2.12 lockable-resources:2.16 log-parser:2.2 mailer:438.v02c7f0a_12fa_4 mapdb-api:1.0.9-28.vf251ce40855d matrix-auth:3.1.5 matrix-project:785.v06b_7f47b_c631 maven-plugin:3.19 mina-sshd-api-common:2.8.0-36.v8e25ce90d4b_1 mina-sshd-api-core:2.8.0-36.v8e25ce90d4b_1 momentjs:1.1.1 msbuild:1.30 naginator:1.18.1 nunit:0.27 okhttp-api:4.9.3-108.v0feda04578cf p4:1.13.0 pam-auth:1.10 parameterized-trigger:2.45 pipeline-build-step:2.18 pipeline-github-lib:38.v445716ea_edda_ pipeline-githubnotify-step:49.vf37bf92d2bc8 pipeline-graph-analysis:195.v5812d95a_a_2f9 pipeline-groovy-lib:612.v84da_9c54906d pipeline-input-step:449.v77f0e8b_845c4 pipeline-milestone-step:101.vd572fef9d926 pipeline-model-api:2.2114.v2654ca_721309 pipeline-model-definition:2.2114.v2654ca_721309 pipeline-model-extensions:2.2114.v2654ca_721309 pipeline-rest-api:2.24 pipeline-stage-step:296.v5f6908f017a_5 pipeline-stage-tags-metadata:2.2114.v2654ca_721309 pipeline-stage-view:2.24 plain-credentials:139.ved2b_9cf7587b plugin-util-api:2.17.0 popper-api:1.16.1-3 popper2-api:2.11.6-1 powershell:1.7 resource-disposer:0.20 run-condition:1.5 scm-api:621.vda_a_b_055e58f7 script-security:1175.v4b_d517d6db_f0 slack:616.v03b_1e98d13dd snakeyaml-api:1.31-84.ve43da_fb_49d0b ssh-credentials:305.v8f4381501156 sshd:3.249.v2dc2ea_416e33 structs:324.va_f5d6774f3a_d theme-manager:1.5 throttle-concurrents:2.9 timestamper:1.19 token-macro:308.v4f2b_ed62b_b_16 trilead-api:1.67.vc3938a_35172f variant:59.vf075fe829ccb violation-comments-to-gitlab:2.55 windows-slaves:1.8.1 wix:1.12 workflow-aggregator:590.v6a_d052e5a_a_b_5 workflow-api:1192.v2d0deb_19d212 workflow-basic-steps:994.vd57e3ca_46d24 workflow-cps:2759.v87459c4eea_ca_ workflow-durable-task-step:1199.v02b_9244f8064 workflow-job:1232.v5a_4c994312f1 workflow-multibranch:716.vc692a_e52371b_ workflow-scm-step:400.v6b_89a_1317c9a_ workflow-step-api:639.v6eca_cd8c04a_a_ workflow-support:838.va_3a_087b_4055b ws-cleanup:0.43
I have two jobs running side by side, a "Freestyle" job and a Matrix or "Multi-Configuration Project" (MCP) configured to do the same simple tasks. For both jobs after a Perforce trigger is received, the jobs will execute a P4-sync of the workspace, then use Powershell to Write-Output a simple message, and finally make a Slack notification.
When a P4 trigger is received the Freestyle job executes as expected. However after the Matrix/MCP job is notified by the same trigger event, it seems unable to process that a change has taken place and never starts the P4-sync or other steps.
By examining the jenkins.err.log I can see an exception is being thrown when Jenkins tries to process the job.
2022-09-15 17:29:26.301+0000 [id=12008] WARNING h.p.b.g.GlobalTimeOutConfiguration#timeOutFor: Tests_P4Trigger_NameVars#1 cannot allow individual jobs to overwrite timeout due to ClassCastException java.lang.ClassCastException: class hudson.matrix.MatrixProject cannot be cast to class hudson.model.Project (hudson.matrix.MatrixProject is in unnamed module of loader jenkins.util.URLClassLoader2 @ab11188; hudson.model.Project is in unnamed module of loader org.eclipse.jetty.webapp.WebAppClassLoader @33bc72d1) at hudson.plugins.build_timeout.global.GlobalTimeOutConfiguration.timeOutFor(GlobalTimeOutConfiguration.java:91) at hudson.plugins.build_timeout.global.GlobalTimeOutRunListener.setUpEnvironment(GlobalTimeOutRunListener.java:43) at hudson.model.AbstractBuild$AbstractBuildExecution.createLauncher(AbstractBuild.java:615) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:483) at hudson.model.Run.execute(Run.java:1899) at hudson.matrix.MatrixBuild.run(MatrixBuild.java:323) at hudson.model.ResourceController.execute(ResourceController.java:107) at hudson.model.Executor.run(Executor.java:449) 2022-09-15 17:29:27.342+0000 [id=12008] INFO o.j.p.p.w.ManualWorkspaceImpl#setClient: P4: Creating manual client: jenkins-built-in-Tests_P4Trigger_NameVars--1 2022-09-15 17:29:27.353+0000 [id=73] INFO o.j.p.p.w.ManualWorkspaceImpl#setClient: P4: Creating manual client: jenkins-BP-JNKND-VS19-6-Tests_P4Trigger_SlackPost-0 2022-09-15 17:29:27.602+0000 [id=11722] INFO o.j.plugins.p4.trigger.P4Hook#probeJobs: P4: probing: DAFI_7-66-SIEI_CLI_VS19
Note the Matrix/MCP job will run successfully if started manually or by a timer. The job only fails after it receives a P4 trigger event.
Reproducibility: Always
Steps to Reproduce:
- Setup a Jenkins server to receive P4 Triggers.
- Setup a Perforce server that triggers a Jenkins server.
- Create a Matrix/MCP project that has a workspace mapping from the Perforce server.
- Use the Manual P4 trigger to run job for the first time.
- Note the first run will work.
- Next submit a change in the Perforce server that will send a trigger to the Jenkins server.
Result:
Jenkins will receive the P4 Trigger, but during the processing of the job the exception above will be thrown, and the Matrix/MCP job will not execute.
Expected Result:
That a Matrix/MCP job would function like a Freestyle job. When a P4 trigger is received the required processing would not throw an exception and instead continue through all the steps.