The p4/change endpoint has good debugging that allows you to see when the endpoint is triggered.
Would help support if the same debugging could applied to p4/event. At the moment no trace of the endpoint being called is seen in the default logging.
Reproduction steps:
(1) Create a multibranch pipeline job.
(2) Call p4/event from 'curl'. For example:
curl --header 'Content-Type: application/json' --user USER:API-TOKEN --request POST --data "payload={change:103,p4port:\"perforce:1666\",event_type:\"UPDATED\"}" http://JENKINS-SERVER:8080/p4/event/
(3) Look in the URL '{JENKINS_URL}/log/all'.
Note - A good hack to make sure the URL is getting through is to unescape the quotes around UPDATED:
curl --header 'Content-Type: application/json' --user USER:API-TOKEN --request POST --data "payload={change:103,p4port:\"perforce:1666\",event_type:"UPDATED"}" http://JENKINS-SERVER:8080/p4/event/
This produces the following error in the Jenkins log:
Aug 26, 2021 11:20:37 AM WARNING org.eclipse.jetty.server.handler.ContextHandler$Context log Error while serving http://JENKINS-SERVER:8080//p4/event/ net.sf.json.JSONException: Unquotted string 'UPDATED'
- is related to
-
JENKINS-64725 /p4/event endpoint doesn't work with the same permission scope as p4/change
-
- Open
-
[JENKINS-66461] Add logging for p4/event endpoint
Link | New: This issue is related to JENKINS-64725 [ JENKINS-64725 ] |
Description |
Original:
The p4/change endpoint has good debugging that allows you to see when the endpoint is triggered.
Would help support if the same debugging could applied to p4/event. At the moment no trace of the endpoint being called is seen in the default logging. +*Reproduction steps:*+ (1) Create a multibranch pipeline job. (2) Call p4/event from 'curl'. For example: {code:java} curl --header 'Content-Type: application/json' --user USER:API-TOKEN --request POST --data "payload={change:103,p4port:\"perforce:1666\",event_type:\"UPDATED\"}" http://JENKINS-SERVER:8080/p4/event/ {code} (3) Look in the URL '\{JENKINS_URL}/log/all'. |
New:
The p4/change endpoint has good debugging that allows you to see when the endpoint is triggered.
Would help support if the same debugging could applied to p4/event. At the moment no trace of the endpoint being called is seen in the default logging. +*Reproduction steps:*+ (1) Create a multibranch pipeline job. (2) Call p4/event from 'curl'. For example: {code:java} curl --header 'Content-Type: application/json' --user USER:API-TOKEN --request POST --data "payload={change:103,p4port:\"perforce:1666\",event_type:\"UPDATED\"}" http://JENKINS-SERVER:8080/p4/event/ {code} (3) Look in the URL '\{JENKINS_URL}/log/all'. Note - A good hack to make sure the URL is getting through is to unescape the quotes around UPDATED: {code:java} curl --header 'Content-Type: application/json' --user USER:API-TOKEN --request POST --data "payload={change:103,p4port:\"perforce:1666\",event_type:"UPDATED"}" http://JENKINS-SERVER:8080/p4/event/ {code} This produces the following error in the Jenkins log: {code:java} Aug 26, 2021 11:20:37 AM WARNING org.eclipse.jetty.server.handler.ContextHandler$Context log Error while serving http://JENKINS-SERVER:8080//p4/event/ net.sf.json.JSONException: Unquotted string 'UPDATED' {code} |