SAP-archive / cloud-s4-sdk-pipeline

The Cloud SDK pipeline uses the Cloud SDK continuous delivery server for building, checking, and deploying extension applications. Projects based on the SAP Cloud SDK archetype will automatically use this pipeline.
Apache License 2.0
65 stars 25 forks source link

Pipeline fails in the LINT stage for v41 #48

Closed srinikitha09 closed 3 years ago

srinikitha09 commented 4 years ago

Issue Description (Mandatory)

The pipeline is failing in the stage: LINT

The pipeline fails while running with v41 during the Lint stage. It fails in checkUi5BestPractices step. Currently, we are using warnings-ng plugin of version 8.3.0. May be do we need to use the latest version of that plugin?

Log Output (Mandatory)

09:53:22  [2020-08-27T07:53:22.003Z] ----------------------------------------------------------
09:53:22  [2020-08-27T07:53:22.003Z]     ERROR OCCURRED IN LIBRARY STEP: checkUi5BestPractices
09:53:22  [2020-08-27T07:53:22.003Z] ----------------------------------------------------------
09:53:22  [2020-08-27T07:53:22.003Z] 
09:53:22  [2020-08-27T07:53:22.003Z] Error Details:
09:53:22  [2020-08-27T07:53:22.003Z] **********************************************************
09:53:22  [2020-08-27T07:53:22.003Z]     java.lang.IllegalArgumentException: WARNING: Unknown parameter(s) found for class type 'io.jenkins.plugins.analysis.core.steps.RecordIssuesStep': skipPublishingChecks
09:53:22  [2020-08-27T07:53:22.003Z] **********************************************************
09:53:22  [2020-08-27T07:53:22.003Z] 
09:53:22  [Pipeline] echo
09:53:22  [2020-08-27T07:53:22.011Z] Parameters available to this step are: [script:WorkflowScript@3969121d, configuration:[ui5BestPractices:[failThreshold:[error:100, warning:500, info:1000]]], ui5Components:[app/webapp/Component.js]]

Link to Jenkins Job (if it can be shared)

PLEASE PLACE THE LINK HERE

Reproduce the Issue Locally (Mandatory)

In case a maven/npm command or similar failed:

Search for existing solution beforehand (Mandatory)

Please try the GitHub search, it works really well

Project Details (Mandatory)

stippi2 commented 4 years ago

Short version: Can you update the version of the Warnings NG plugin to 8.4.1? The property will exist then and your pipeline should not fail anymore. Please let us know your findings.

Long version: There was a regression introduced in the Warnings NG plugin with this commit. It activates a feature by default, which requires the Jenkins "Root-URL" to be configured. This URL is normally configured, but not in all use-cases of the CX Server. My work-around was to set the new parameter "skipPublishingChecks" for the recordIssues step in order to de-activate the new feature. This however, would not have solved the issue for anyone consuming the Cloud SDK Pipeline in a version that does not contain that fix. And so we also fixed the version of the Warnings NG plugin to 8.3.0 in the CX Server scripts. This means we should see the same failure as you in our internal tests, since we also run with version 8.3.0 of the plugin. But for some reason, it is just a warning in our logs and no pipeline failure. So we were unaware that passing the property to recordIssues is actually wrong and should have been removed again.

stippi2 commented 4 years ago

I have created a backlog issue to solve this problem. I assume we can simply pass the property depending on the plugin-version and we will fix this soon.

Can I close this ticket, because upgrading the plugin worked and the issue is solved for you?

srinikitha09 commented 4 years ago

Thanks for the clarity. We did not upgrade the plugin yet. Of course, you can close the ticket. We have another backlog item, which enables the usage of specific jenkinsfilerunner image for each kind of job. Once, this is achieved, we would not have problem with the versions update of plugins.

Because, currently, we are afraid if upgrading the warnings-ng plugin to 8.4.1 still supports the older version of cloud sdk pipeline ex: v39 which worked with warnings-ng 8.3.0 version.

KevinHudemann commented 3 years ago

Hi @srinikitha09, the issue in the SAP Cloud SDK Pipeline has been resolved by @stippi2 in version v42, thus closing this issue.

Due to the deprecation of the SAP Cloud SDK Pipeline, however, we recommend the switch to the General Purpose Pipeline of project "Piper" where the issue you reported is not resolved yet. If you want to stay informed about the progress there, please feel free to open an issue in the repository of the General Purpose Pipeline of project "Piper". Best Regards, Kevin