Open msymons opened 5 years ago
I discovered what was wrong. ONE Jenkins server failed to upgrade to the new dependency-track plugin 2.2.0 and, of course, it was the one with the "GitHub Stats" job.
After the plugin was updated for real, the job is now OK.
Therefore, this issue is not a defect. But I do think it warrants labelling as an enhancement... that Dependency-Track should be returning HTTP 400 and not HTTP 500 in such cases.
Current Behavior:
After installing dependency-track plugin 2.2.0 (released 4 November 2019) and updating pipelines that use "name + version" to start using synchronous mode, I have many pipeline jobs that seem to be publishing fine. However, I have at least one that is failing the build with an HTTP 500 error.
Steps to Reproduce:
Not quite sure, as the logging in neither server nor jenkins plugin is quite telling me what is being submitted.
However, this is what should have been submitted to lookup:
GitHub Stats
1.x
I deleted the project in DT and it was then correctly recreated by the pipeline using the above name/version.
Expected Behavior:
1) DT should really be generating an HTTP 400 response instead of HTTP 500... and provide content that contains information on what went wrong. However, the API does not document HTTP 400, 2) Separate to DT... it would help if the publisher provided more information on what it is doing. eg, what name and version it is submitting to lookup, etc.
Environment:
Additional Details:
From Jenkins Console logging for build...
Compare with a job that is working fine:
From
dependency-track.log
for problem job:Note that metrics are executed twice. Is this intended?
From Dependency-Track
server.log