I have a Jenkinsfile that runs a pipeline. The pipeline runs correctly on one instance of Jenkins, so I believe there isn't a problem with my script.
I am now trying to copy the job over to another instance, but I get the following error in the console output:
Started by user
[Pipeline] End of Pipeline
java.lang.AbstractMethodError: Method org/jenkinsci/plugins/workflow/cps/global/UserDefinedGlobalVariableList.iterator()Ljava/util/Iterator; is abstract
at org.jenkinsci.plugins.workflow.cps.global.UserDefinedGlobalVariableList.iterator(UserDefinedGlobalVariableList.java)
at org.jenkinsci.plugins.workflow.cps.GlobalVariable$1$1.expand(GlobalVariable.java:74)
at org.jenkinsci.plugins.workflow.cps.GlobalVariable$1$1.expand(GlobalVariable.java:71)
at hudson.util.Iterators$FlattenIterator.hasNext(Iterators.java:74)
at org.jenkinsci.plugins.workflow.cps.CpsScript.invokeMethod(CpsScript.java:100)
at org.codehaus.groovy.runtime.callsite.PogoMetaClassSite.call(PogoMetaClassSite.java:45)
at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:42)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:108)
at com.cloudbees.groovy.cps.sandbox.DefaultInvoker.methodCall(DefaultInvoker.java:15)
at WorkflowScript.run(WorkflowScript:3)
at ___cps.transform___(Native Method)
at com.cloudbees.groovy.cps.impl.ContinuationGroup.methodCall(ContinuationGroup.java:55)
at com.cloudbees.groovy.cps.impl.FunctionCallBlock$ContinuationImpl.dispatchOrArg(FunctionCallBlock.java:106)
at com.cloudbees.groovy.cps.impl.FunctionCallBlock$ContinuationImpl.fixArg(FunctionCallBlock.java:79)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:483)
at com.cloudbees.groovy.cps.impl.ContinuationPtr$ContinuationImpl.receive(ContinuationPtr.java:72)
at com.cloudbees.groovy.cps.impl.ClosureBlock.eval(ClosureBlock.java:40)
at com.cloudbees.groovy.cps.Next.step(Next.java:58)
at com.cloudbees.groovy.cps.Continuable.run0(Continuable.java:154)
at org.jenkinsci.plugins.workflow.cps.CpsThread.runNextChunk(CpsThread.java:164)
at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup.run(CpsThreadGroup.java:297)
at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup.access$000(CpsThreadGroup.java:78)
at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup$2.call(CpsThreadGroup.java:206)
at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup$2.call(CpsThreadGroup.java:204)
at org.jenkinsci.plugins.workflow.cps.CpsVmExecutorService$2.call(CpsVmExecutorService.java:47)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at hudson.remoting.SingleLaneExecutorService$1.run(SingleLaneExecutorService.java:112)
at jenkins.util.ContextResettingExecutorService$1.run(ContextResettingExecutorService.java:28)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
Finished: FAILURE
Jenkinsfile for reference:
#!/usr/bin/env groovy
node {
stage('build')
echo 'hello world'
}
I believe I've messed up a plugin, but not sure which one. Here's the list of installed plugins and also the installed version of Jenkins:
Jenkins v1.651.3
=========
Ant Plugin
Uses the OWASP Java HTML Sanitizer to allow safe-seeming HTML markup to be entered in project descriptions and the like.
1.2
Artifact Deployer Plug-in
This plug-in makes it possible to deploy artifacts from workspace to output directories.
0.33
Artifactory Plugin
This plugin allows deploying maven artifacts and build info to Artifactory.
2.4.7
Async Http Client
This plugin provides a shared dependency on the async-http-client library so that other plugins can co-operate when using this library.
1.7.24
Authentication Tokens API Plugin
This plugin provides an API for converting credentials into authentication tokens in Jenkins.
1.2
Branch API Plugin
This plugin provides an API for multiple branch based projects.
1.11
Build Authorization Token Root Plugin
Lets build and related REST build triggers be accessed even when anonymous users cannot see Jenkins.
1.4
Build Pipeline Plugin
This plugin renders upstream and downstream connected jobs that typically form a build pipeline. In addition, it offers the ability to define manual triggers for jobs that require intervention prior to execution, e.g. an approval process outside of Jenkins.
1.5.2
build timeout plugin
This plugin allows builds to be automatically terminated after the specified amount of time has elapsed.
1.16
Build Trigger Badge Plugin
This plugin displays an icon representing the cause of a construction.
2.2
Build With Parameters
Allows the user to provide parameters for a build in the url (similar to /job/JOBNAME/buildWithParameters), prompting for confirmation before triggering the job.
1.3
build-name-setter
This plug-in sets the display name of a build to something other than #1, #2, #3, ...
1.5.1
CCCC Plug-in
This plugin parses CCCC output files to produce project and build reports.
0.6
CloudBees Docker Build and Publish plugin
This plugin enables building Dockerfile based projects, as well as publishing of the built images/repos to the docker registry.
1.2.2
CloudBees Docker Hub/Registry Notification
Integrates Jenkins with DockerHub and Docker Registry
2.0
CloudBees Docker Traceability
Provides an ability to trace server deployments via fingerprints
1.2
Cobertura Plugin
This plugin integrates Cobertura coverage reports to Jenkins.
1.9.7
Config File Provider Plugin
Ability to provide configuration files (e.g. settings.xml for maven, XML, groovy, custom files,...) loaded through the UI which will be copied to the job workspace.
2.10.1
Confluence Publisher
This plugin allows you to publish build artifacts into a Confluence wiki page. Currently limited to uploading an artifact as an attachment to a page id.
1.8
Copy Artifact Plugin
Adds a build step to copy artifacts from another project.
1.37
Credentials Binding Plugin
Allows credentials to be bound to environment variables for use from miscellaneous build steps.
1.10
Credentials Plugin
This plugin allows you to store credentials in Jenkins.
2.1.1
Crowd 2 Integration
This plugin enables use of Atlassian Crowd as an authentication source. It uses Crowd's REST API (available since Crowd 2.1) to access the services and supports single-sign-on.
1.9-SNAPSHOT (private-04/03/2015 19:47-arnaud)
Cucumber Plugin
run cucumber tests under jenkins CI
0.0.2
Cucumber reports
This project provides pretty html reports for Cucumber. It works by generating html from the cucumber json report formatter. Can be used anywhere a json report is generated (Java, Ruby, JavaScript and other implementations).
3.6.0
CVS Plug-in
Integrates Jenkins with CVS version control system using a modified version of the Netbeans cvsclient.
2.12
Deploy to container Plugin
This plugin allows you to deploy a war to a container after a successful build.
Glassfish 3.x remote deployment
1.10
Deploy to Websphere container Plugin
1.0
deployment-notification
This plugin provides abstract common parts for integration with configuration management tools like Chef and Puppet.
1.4
Discard Old Build plugin
This plugin enables detail configuration to discard old builds like using logfile size / status / days/ intervals days / build num / logfile regular expression.
1.05
disk-usage plugin
This plugin counts disk usage.
0.28
Docker Commons Plugin
Provides the common shared functionality for various Docker-related plugins.
1.6
Docker Pipeline
Build and use Docker containers from pipelines.
1.6
Docker plugin
This plugin integrates Jenkins with Docker
0.16.0
docker-build-step
This plugin allows to add various docker commands to your job as build steps.
1.39
Durable Task Plugin
Library offering an extension point for processes which can run outside of Jenkins yet be monitored.
1.9
Dynamic Parameter Plug-in
This plugin allows build parameters with dynamically generated default values.
0.2.0
Email Ext Recipients Column Plugin
This plugin is a sample to explain how to write a Jenkins plugin.
1.0
Email Extension Plugin
This plugin is a replacement for Jenkins's email publisher
2.41.3
Email Extension Template Plugin
This plugin allows administrators to create global templates for the Extended Email Publisher.
0.4
Environment Dashboard Plugin
This plugin is used to generate the Environment Dashboard.
1.1.4
Environment File Plugin
This plugin can be used to set environment variables from a file.
1.2
Environment Injector Plugin
This plugin makes it possible to set an environment for the builds.
1.92.1
export dynamic job data
This plugin exports Jenkins runtime job parameters into a properties file.
0.4
Extended Choice Parameter Plug-In
Adds extended functionality to Choice parameter
0.74
Extensible Choice Parameter plugin
Extensible Choice Parameter provides several ways to retrieve choices, including the way to share choices among all jobs.
1.3.2
External Monitor Job Type Plugin
Adds the ability to monitor the result of externally executed jobs
1.4
Flexible Publish Plugin
Choose the order of publisher execution and make the execution conditional
0.15.2
Folders Plugin
This plugin allows users to create "folders" to organize jobs. Users can define custom taxonomies (like by project type, organization type etc). Folders are nestable and you can define views within folders. Maintained by CloudBees, Inc.
5.12
Gatling Jenkins Plugin
This plugin integrates Gatling simulation reports into Jenkins.
1.1.1
Git Changelog
Plugin creating JIRA filter URL based on commit messages containing JIRA ticket keys in the GIT history
1.2
Git client plugin
Utility plugin for Git support in Jenkins
1.19.6
Git Parameter Plug-In
Adds ability to choose from git repository revisions or tags
0.4.0
Git plugin
This plugin integrates Git with Jenkins.
2.5.2
GIT server Plugin
Allows Jenkins to act as a Git server.
1.6
Git Tag Message Plugin
Exports the message for a git tag as an environment variable during a build.
1.4
git-notes Plugin
Add git-notes with Jenkins build status!
0.0.4
Gitcolony Build Notification plugin
This plugin updates live branch build status in Gitcolony.
1.1
GitHub API Plugin
This plugin provides GitHub API for other plugins.
1.71
GitHub Authentication plugin
This is the an authentication plugin using github OAuth.
0.22.2
GitHub plugin
This plugin integrates GitHub to Jenkins.
1.16.0
Gradle Plugin
This plugin allows Jenkins to invoke Gradle build scripts directly.
1.24
Green Balls
Because green is better than blue! For color blind support configure user property.
1.15
Groovy
This plugin executes Groovy code.
1.3
HP Application Automation Tools
This plugin allows integration with HP ALM, HP Unified Functional Testing, HP LoadRunner and HP Performance cente
4.0.1
HPE Security Fortify Jenkins Plugin
HPE Security Fortify Jenkins Plugin, publish FPR result in Project page, upload FPR to Software Security Center (SSC), consider a build as fail if too many vulnerabilities
1.16.10
HTML Publisher plugin
This plugin publishes HTML reports.
1.11
HTTP Request Plugin
This plugin sends a http request to an url with some parameters. See the release notes for changes and compatibility https://github.com/jenkinsci/http-request-plugin/releases
1.8.11
Hudson SCP publisher plugin
This plugin uploads build artifacts to repository sites using SCP (SSH) protocol.
1.8
Icon Shim Plugin
Allows plugins make full use of the <l:icon> layout tag when running on newer versions of Jenkins, while still being compatible with older versions.
2.0.3
JaCoCo plugin
1.0.16
Javadoc Plugin
1.3
JavaScript GUI Lib: ACE Editor bundle plugin
JavaScript GUI Lib: ACE Editor bundle plugin.
1.1
JavaScript GUI Lib: Handlebars bundle plugin
JavaScript GUI Lib: Handlebars bundle plugin.
1.1
JavaScript GUI Lib: jQuery bundles (jQuery and jQuery UI) plugin
JavaScript GUI Lib: jQuery bundles (jQuery and jQuery UI) plugin.
1.2.1
JavaScript GUI Lib: Moment.js bundle plugin
JavaScript GUI Lib: Moment.js bundle plugin.
1.1
JIRA plugin
This plugin integrates Jenkins to Atlassian JIRA.
2.1
Job Configuration History Plugin
Job history plugin for Jenkins.
2.13
Job DSL
This plugin allows Jobs and Views to be defined via DSLs
1.45
Job Import Plugin
The Job Import Plugin lets you import jobs from another Jenkins instance.
1.3.1
Job/Queue/Slaves Monitoring Plugin
This plugin shows different information about the queue, slaves and jobs in jenkins.
1.4
jQuery plugin
This allows other plugins to use jQuery in UI.
1.11.2-0
jQuery UI plugin
This plugin allows you to use jQuery UI on view descriptions.
1.0.2
JUnit Plugin
Allows JUnit-format test results to be published.
1.10
Kubernetes plugin
Jenkins plugin to run dynamic slaves in a Kubernetes/Docker environment
0.7
LDAP Plugin
Adds LDAP authentication to Jenkins
1.11
Mailer Plugin
This plugin allows you to configure email notifications for build results
1.16
Managed Scripts
This plugin allows to centrally manage shell scripts and reference these as build steps in your builds.
1.2.1
MapDB API Plugin
This plugin provides a shared dependency on the MapDB library so that other plugins can co-operate when using this library.
1.0.6.0
Mask Passwords Plugin
This plugin allows masking passwords that may appear in the console.
2.8
Matrix Authorization Strategy Plugin
Offers matrix-based security authorization strategies (global and per-project).
1.2
Matrix Project Plugin
Multi-configuration (matrix) project type.
1.6
Maven Integration plugin
This plug-in provides, for better and for worse, a deep integration of Jenkins and Maven: Automatic triggers between projects depending on SNAPSHOTs, automated configuration of various Jenkins publishers (Junit, ...).
2.12.1
Maven Metadata Plugin for Jenkins CI server
Adds a build parameter that presents versions of an artifact from a maven repository as a drop down list.
1.5.0
Monitoring
Jenkins' monitoring with JavaMelody. Open report after installation.
1.59.0
Multiple SCMs plugin
This plugin enables the selection of multiple source code management systems for a build. For example, it enables checking out the source code from one SCM while checking out legacy or third-party code from another.
0.6
Next Build Number Plugin
Sets the build number Jenkins will use for a job's next build
1.4
NodeJS Plugin
NodeJS Plugin executes NodeJS script as a build step.
0.2.1
OpenShift Deployer Plugin
This plugin enable Jenkins jobs to create containers(gears) on OpenShift and deploy applications to it
1.2.0
OpenShift Pipeline Jenkins Plugin
This plugin facilitates the construction of jobs, pipelines, and workflows that operate on a Kubernetes based OpenShift server.
1.0.21
OpenShift Sync
Syncs OpenShift BuildConfigs with Jenkins jobs
0.0.11
OWASP Markup Formatter Plugin
Uses the OWASP Java HTML Sanitizer to allow safe-seeming HTML markup to be entered in project descriptions and the like.
1.3
PAM Authentication plugin
Adds Unix Pluggable Authentication Module (PAM) support to Jenkins
1.2
Parameterized Remote Trigger Plugin
This plugin triggers a job on a remote Jenkins host
2.2.2
Parameterized Trigger plugin
2.30
Performance Plugin
This plugin integrates JMeter reports, JUnit reports, wrk output, and Iago reports into Hudson.
1.13
Pipeline
A suite of plugins that lets you orchestrate automation, simple or complex. See Pipeline as Code with Jenkins for more details.
2.5
Pipeline Graph Analysis Plugin
Provides a REST API to access pipeline and pipeline run data.
1.3
Pipeline: API
Plugin that defines Pipeline API.
2.1
Pipeline: Basic Steps
Commonly used steps for Pipelines.
2.4
Pipeline: Build Step
Adds the Pipeline step build to trigger builds of other jobs.
2.4
Pipeline: Declarative Extension Points API
APIs for extension points used in Declarative Pipelines.
1.1.1
Pipeline: GitHub Groovy Libraries
Allows Pipeline Grrovy libraries to be loaded on the fly from GitHub.
1.0
Pipeline: Groovy
Pipeline execution engine based on continuation passing style transformation of Groovy scripts.
2.9
Pipeline: Input Step
Adds the Pipeline step input to wait for human input or approval.
2.5
Pipeline: Job
Defines a new job type for pipelines and provides their generic user interface.
2.3
Pipeline: Milestone Step
Plugin that provides the milestone step
1.3
Pipeline: Model API
Model API for Declarative Pipeline.
1.1.1
Pipeline: Model Definition
An opinionated, declarative Pipeline.
1.1.1
Pipeline: Multibranch
Enhances Pipeline plugin to handle branches better by automatically grouping builds from different branches.
2.9.2
Pipeline: Nodes and Processes
Pipeline steps locking agents and workspaces, and running external processes that may survive a Jenkins restart or slave reconnection.
2.10
Pipeline: REST API Plugin
Provides a REST API to access pipeline and pipeline run data.
1.5
Pipeline: SCM Step
Adds a Pipeline step to check out or update working sources from various SCMs (version control).
2.2
Pipeline: Shared Groovy Libraries
Shared libraries for Pipeline scripts.
2.7
Pipeline: Stage Step
Adds the Pipeline step stage to delineate portions of a build.
2.2
Pipeline: Stage Tags Metadata
Library plugin for Pipeline stage tag metadata.
1.1.1
Pipeline: Stage View Plugin
Pipeline Stage View Plugin.
2.6
Pipeline: Step API
API for asynchronous build step primitive.
2.9
Pipeline: Supporting APIs
Common utility implementations to build Pipeline Plugin
2.13
Plain Credentials Plugin
Allows use of plain strings and files as credentials.
1.1
Port Allocator Plug-in
This plugin allocates free ports as environment variables.
1.8
Post-Build Script Plug-in
No description available.
0.17
Promoted Builds (Simple)
Simpler version of Promoted Builds plugin, with only manual promotion of builds.
1.9
promoted builds plugin
This plugin implements a "promoted build" feature where a build of one job can be marked as "promoted" when it passes certain criteria.
2.27
Publish Over SSH
Send build artifacts over SSH
1.14
PWauth Security Realm
This plug-in adds authentication via pwauth and supports both *nix system users and groups through PAM.
0.4
ready-api-jenkins-plugin
The Ready! API Plugin can be used to start and stop ServiceV Virts during your builds.
1.8.5
Reverse Proxy Auth Plugin
1.4.0
Role-based Authorization Strategy
Enables authorization using a role-based strategy.
2.3.2
ruby-runtime
Hosts runtime for enabling pure-Ruby plugins
0.12
Run Condition Extras Plugin
Plugin provides extra run conditions and plugin integrations for Run Conditions Plugin.
0.2
Run Condition Plugin
Define conditions for the execution of build steps
1.0
Safe Restart Plugin
This plugin allows you to restart Jenkins safely.
0.3
sbt plugin
This plugin allows running SBT empowered scala projects in Hudson.
1.5
SCM API Plugin
This plugin provides a new enhanced API for interacting with SCM systems.
1.2
Scoverage Plugin
Scoverage Plugin
1.3.2
Script Security Plugin
Allows Jenkins administrators to control what in-process scripts can be run by less-privileged users.
1.21
Scriptler
Scriptler allows you to store/edit/execute groovy scripts on any of the slaves/nodes... no need for copy paste groovy code anymore. Beside administer your scripts, Scritpler also provides a way to share scripts between users via hosted script catalogs on the internet.
2.9
Security Realm by custom script
This plugin adds authentication via user-defined script, in additon to the orignal script-realm, this one also supports groups.
1.5
Selenium HTML report
This is an jenkins plugin to visualize the results of selenium tests
1.0
Shared Objects Plugin
This plugin makes it possible to populate as environment variables some objects such as public file paths, Clearcase objects, locations of installed tools and so on. This plugin contributes to the EnvInject plugin.
0.44
SonarQube Plugin
This plugin allows an easy integration of SonarQube, the open source platform for Continuous Inspection of code quality.
2.3
SSH Agent Plugin
1.9
SSH Credentials Plugin
Allows storage of SSH credentials in Jenkins
1.11
SSH plugin
This plugin executes shell commands remotely using SSH protocol.
2.4
SSH Slaves plugin
Allows to launch agents over SSH, using a Java implementation of the SSH protocol
1.10
Static Analysis Collector Plug-in
This plug-in is an add-on for the plug-ins Checkstyle, Dry, FindBugs, PMD, Tasks, and Warnings: the plug-in collects the different analysis results and shows the results in a combined trend graph. Additionally, the plug-in provides health reporting and build stability based on these combined results.
1.47
Static Analysis Utilities
This plug-in provides utilities for the static code analysis plug-ins.
1.76
Structs Plugin
Library plugin for DSL plugins that need names for Jenkins objects.
1.4
Subversion Plug-in
2.5.7
TestNG Results Plugin
This plugin integrates TestNG test reports to Jenkins.
1.13
ThinBackup
Backs up the most important global and job specific configuration files.
1.7.4
Timestamper
Adds timestamps to the Console Output
1.7.2
Token Macro Plugin
This plug-in adds reusable macro expansion capability for other plug-ins to use.
1.12.1
Translation Assistance plugin
1.12
Validating String Parameter Plugin
Adds a new parameter type called Validating String Parameter which supports regular expression validation of a user entered parameter.
2.3
WAS Builder Plugin
This plugin adds an "IBM WebSphere Application Server 6.x/7.x" builder which allows running wsadmin commands (or scripts) from a job.
1.6.1
WebSphere Deployer Plugin
Deploys your web artifacts automatically to IBM WebSphere Application Server and IBM WebSphere Liberty Profile
1.3.4
Windows Slaves Plugin
Allows you to connect to Windows machines and start slave agents on them.
1.1
Zentimestamp plugin
Plugin that allows the customization of the date and time pattern for the Jenkins BUILD_TIMESTAMP variable.
4.2
The following line gives the hint, where the error occurs in your pipeline script:
at WorkflowScript.run(WorkflowScript:3)
While line 3 in the pasted script is the node, I assume that something is odd with numbering and see an error in the parameters call (which would be line 3, if you start from the first line where the script starts.. not sure if this makes sense).
The reason, why this parameters would fail is that you copied this snippet from a Declarative Pipeline, but (as you don't have the pipeline wrapper, you're running a Scripted Pipeline.
For scripted pipelines, you have to use the build properties to define the parameters:
properties([
parameters([
string(name: 'dockerTag', defaultValue: '1.0', description: 'What is the docker tag?')
])
])
(as this is not obvious and not very well documented, I wrote a blog post a few months ago)
Yes
The following line gives the hint, where the error occurs in your pipeline script:
at WorkflowScript.run(WorkflowScript:3)
While line 3 in the pasted script is the node, I assume that something is odd with numbering and see an error in the parameters call (which would be line 3, if you start from the first line where the script starts.. not sure if this makes sense).
The reason, why this parameters would fail is that you copied this snippet from a Declarative Pipeline, but (as you don't have the pipeline wrapper, you're running a Scripted Pipeline.
For scripted pipelines, you have to use the build properties to define the parameters:
properties([
parameters([
string(name: 'dockerTag', defaultValue: '1.0', description: 'What is the docker tag?')
])
])
(as this is not obvious and not very well documented, I wrote a blog post a few months ago)
Related
I had to skip past the default plugin install page to configure proxy and to fix an issue. But now I need to install default plugins. Is there a way restart the default plugin installation page without having to delete Jenkins container? Or is there a list of default plugin names somewhere where I can manually install.
Here's a list with all of the default plugins, suggested for Jenkins version 2.60.3:
Folders
OWASP Markup Formatter
Structs
Pipeline: Step API
Token Macro
Build Timeout
Credentials
Trilead API
SSH Credentials
Plain Credentials
Credentials Binding
SCM API
Pipeline: API
Timestamper
Script Security
JUnit
Matrix Project
Resource Disposer
Workspace Cleanup
Ant
Pipeline: Supporting APIs
Durable Task
Pipeline: Nodes and Processes
Pipeline: SCM Step
Pipeline: Groovy
Pipeline: Job
Display URL API
Mailer
Pipeline: Basic Steps
Gradle
Pipeline: Milestone Step
Snakeyaml API
Jackson 2 API
Pipeline: Input Step
Pipeline: Stage Step
Pipeline Graph Analysis
Pipeline: REST API
Pipeline: Stage View
Pipeline: Build Step
Pipeline: Model API
Pipeline: Declarative Extension Points API
JSch dependency
Git client
GIT server
Pipeline: Shared Groovy Libraries
Branch API
Pipeline: Multibranch
Pipeline: Stage Tags Metadata
Pipeline: Declarative
Lockable Resources
Pipeline
OkHttp
GitHub API
Git
GitHub
GitHub Branch Source
Pipeline: GitHub Groovy Libraries
Subversion
SSH Build Agents
Matrix Authorization Strategy
PAM Authentication
LDAP
Email Extension
seems like, better to re-install jenkins
We have Jenkins with a couple of plugins. Including the Groovy-Pipeline plugin. Problem is that Jenkins sometime does not run and we get the message:
Sep 12, 2017 3:33:16 PM hudson.ExpressionFactory2$JexlExpression evaluate
WARNING: Caught exception evaluating: job.buildHealthReports in /. Reason: java.lang.reflect.InvocationTargetException
java.lang.reflect.InvocationTargetException
at sun.reflect.GeneratedMethodAccessor108.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.apache.commons.jexl.util.PropertyExecutor.execute(PropertyExecutor.java:125)
at org.apache.commons.jexl.util.introspection.UberspectImpl$VelGetterImpl.invoke(UberspectImpl.java:314)
Caused by: java.lang.LinkageError: loader (instance of org/jenkinsci/plugins/workflow/cps/CpsGroovyShell$CleanGroovyClassLoader): attempted duplicate class definition for name: "lib/lib"
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:763)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
When I disable the plugin the error goes away.
Notable is that it seems to handle around "job.buildHealthReports" and that the problem is "lib/lib". I assume some duplicate library loading...
Installed plugins:
Enabled Name ↓ Version Previously installed version
Pinned Uninstall Allure Jenkins Plugin This plugin
integrates Allure reporting tool into Jenkins.
2.22
AnsiColor Adds ANSI coloring to the Console Output
0.5.2
Ant Plugin Adds Apache Ant support to Jenkins
1.7
Authentication Tokens API Plugin This plugin provides an API for converting credentials into authentication tokens in Jenkins.
1.3 Autofavorite for Blue Ocean Automatically favorites multibranch pipeline jobs when user is the author
1.0.0
Bitbucket Branch Source Plugin Allows to use Bitbucket Cloud as a source for multi-branch projects. It also provides the required
connectors for Bitbucket Cloud Team Folder (also known as repositories
auto-discovering).
2.2.3 Bitbucket Pipeline for Blue Ocean BlueOcean Bitbucket pipeline creator
1.2.0
Blue Ocean BlueOcean Aggregator
1.2.0
Blue Ocean Pipeline Editor The Blue Ocean Pipeline Editor is the simplest way for anyone wanting to get started with creating Pipelines
in Jenkins
1.2.0
bouncycastle API Plugin This plugin provides an stable API to Bouncy Castle related tasks.
2.16.2
Branch API Plugin This plugin provides an API for multiple branch based projects.
2.0.11
Build Monitor View Provides a highly visible view of the status of selected Jenkins jobs. It easily accommodates different computer
screen sizes and is ideal as an Extreme Feedback Device to be
displayed on a screen on your office wall.
1.12+build.201704111018
Common API for Blue Ocean This plugin is a part of Blue Ocean UI
1.2.0
Config API for Blue Ocean BlueOcean Analytics Tools plugin
1.2.0
Config File Provider Plugin Ability to provide configuration files (e.g. settings.xml for maven, XML, groovy, custom files,...)
loaded through the UI which will be copied to the job workspace.
2.16.3 Credentials Binding Plugin Allows credentials to be bound to environment variables for use from miscellaneous build steps.
1.13
Credentials Plugin This plugin allows you to store credentials in Jenkins.
2.1.15
Cucumber json test reporting. This plugin understands cucumber json files and converts them to Jenkins TestCase so they can be seen
in the standard test reports.
0.9.7 Cucumber reports This project provides pretty html reports for Cucumber. It works by generating html from the cucumber json
report formatter. Can be used anywhere a json report is generated
(Java, Ruby, JavaScript and other implementations).
3.10.1
Dashboard for Blue Ocean Blue Ocean Dashboard
1.2.0
Display URL API Provides the DisplayURLProvider extension point to provide alternate URLs for use in notifications
2.0
Display URL for Blue Ocean This plugin generates BlueOcean specific URLs for the Display URL plugin.
2.1.0
Docker Commons Plugin Provides the common shared functionality for various Docker-related plugins.
1.8
Docker Pipeline Build and use Docker containers from pipelines.
1.12
Durable Task Plugin Library offering an extension point for processes which can run outside of Jenkins yet be monitored.
1.14
Events API for Blue Ocean Blue Ocean Events
1.2.0
External Monitor Job Type Plugin Adds the ability to monitor the result of externally executed jobs
1.7 Favorite This plugin allows users to favorite a job.
2.3.0
Folders Plugin This plugin allows users to create "folders" to organize jobs. Users can define custom taxonomies (like by project
type, organization type etc). Folders are nestable and you can define
views within folders. Maintained by CloudBees, Inc.
6.1.2
Git client plugin Utility plugin for Git support in Jenkins
2.5.0
Git Pipeline for Blue Ocean BlueOcean Git SCM pipeline creator
1.2.0
Git plugin This plugin integrates Git with Jenkins.
3.5.1
GIT server Plugin Allows Jenkins to act as a Git server.
1.7 GitHub API Plugin This plugin provides GitHub API for other plugins.
1.86
GitHub Branch Source Plugin Multibranch projects and organization folders from GitHub. Maintained by CloudBees, Inc.
2.2.3
GitHub Organization Folder Plugin The functionality that was provided by this plugin has been moved to the GitHub Branch Source
plugin. You can safely delete this plugin once there are no plugins
that depend on this plugin installed.
1.6 GitHub Pipeline for Blue Ocean BlueOcean GitHub organization pipeline creator
1.2.0
GitHub plugin This plugin integrates GitHub to Jenkins.
1.28.0
Green Balls Because green is better than blue! For color blind support configure user property.
1.15 Hidden Parameter plugin
0.0.4 HipChat Plugin This plugin is a HipChat notifier that can publish build status to HipChat rooms.
2.1.1 HTML Publisher plugin This plugin publishes HTML reports.
1.14 i18n for Blue Ocean Blue Ocean Internationalization (i18n) Plugin. This plugin is a part of the Blue Ocean Plugin set.
1.2.0
Icon Shim Plugin Allows plugins make full use of the layout tag when running on newer versions of Jenkins, while still
being compatible with older versions.
2.0.3 Jackson 2 API Plugin This plugin exposes the Jackson 2 JSON APIs to other Jenkins plugins.
2.7.3 Javadoc Plugin
1.4 JavaScript GUI Lib: ACE Editor bundle plugin JavaScript GUI Lib: ACE Editor bundle plugin.
1.1 JavaScript GUI Lib: Handlebars bundle plugin JavaScript GUI Lib: Handlebars bundle plugin.
1.1.1 JavaScript GUI Lib: jQuery bundles (jQuery and jQuery UI) plugin JavaScript GUI Lib: jQuery bundles (jQuery and jQuery UI)
plugin.
1.2.1 JavaScript GUI Lib: Moment.js bundle plugin JavaScript GUI Lib: Moment.js bundle plugin.
1.1.1 JIRA plugin This plugin integrates Jenkins to Atlassian JIRA.
2.4.2 jQuery plugin This allows other plugins to use jQuery in UI.
1.11.2-0 JUnit Plugin Allows JUnit-format test results to be published.
1.21
JWT for Blue Ocean BlueOcean JWT plugin: Enables JWT based BlueOcean API authentication
1.2.0
Kubernetes plugin Jenkins plugin to run dynamic slaves in a Kubernetes/Docker environment
1.0
LDAP Plugin Adds LDAP authentication to Jenkins
1.16
Mailer Plugin This plugin allows you to configure email notifications for build results
1.20
Matrix Authorization Strategy Plugin Offers matrix-based security authorization strategies (global and per-project).
1.7
Matrix Project Plugin Multi-configuration (matrix) project type.
1.11
Maven Integration plugin This plug-in provides, for better and for worse, a deep integration of Jenkins and Maven: Automatic triggers
between projects depending on SNAPSHOTs, automated configuration of
various Jenkins publishers (Junit, ...).
2.17
Maven Release Plug-in Plug-in A plug-in that enables you to perform releases using the maven-release-plugin from Jenkins.
0.14.0 Mercurial plugin This plugin integrates Mercurial SCM with Hudson. It includes repository browsing support for hg
serve/hgweb, Google Code, Bitbucket, FishEye, KilnHG and RhodeCode.
Features include guaranteed clean builds, named branch support, module
lists, Mercurial tool installation, and automatic caching.
2.1 Metrics Plugin This plugin exposes the Metrics API to Jenkins plugins.
3.1.2.10
NodeJS Plugin NodeJS Plugin executes NodeJS script as a build step.
1.2.4
OWASP Markup Formatter Plugin Uses the OWASP Java HTML Sanitizer to allow safe-seeming HTML markup to be entered in project
descriptions and the like.
1.5 PAM Authentication plugin Adds Unix Pluggable Authentication Module (PAM) support to Jenkins
1.3 Personalization for Blue Ocean Blue Ocean Personalization
1.2.0
Pipeline A suite of plugins that lets you orchestrate automation, simple or complex. See Pipeline as Code with Jenkins for more details.
2.5
Pipeline Graph Analysis Plugin Provides a REST API to access pipeline and pipeline run data.
1.5
Pipeline implementation for Blue Ocean This plugin is a part of BlueOcean Plugin
1.2.0
Pipeline SCM API for Blue Ocean This plugin is a part of BlueOcean Plugin
1.2.0
Pipeline Utility Steps Utility steps for pipeline jobs.
1.4.0
Pipeline: API Plugin that defines Pipeline API.
2.20
Pipeline: Basic Steps Commonly used steps for Pipelines.
2.6
Pipeline: Build Step Adds the Pipeline step build to trigger builds of other jobs.
2.5.1
Pipeline: Declarative Agent API Replaced by Pipeline: Declarative Extension Points API plugin.
1.1.1
Pipeline: Declarative Extension Points API APIs for extension points used in Declarative Pipelines.
1.1.9
Pipeline: GitHub Groovy Libraries Allows Pipeline Grrovy libraries to be loaded on the fly from GitHub.
1.0 Pipeline: Groovy Pipeline execution engine based on continuation passing style transformation of Groovy scripts.
2.40
Pipeline: Input Step Adds the Pipeline step input to wait for human input or approval.
2.8
Pipeline: Job Defines a new job type for pipelines and provides their generic user interface.
2.11.2
Pipeline: Milestone Step Plugin that provides the milestone step
1.3.1
Pipeline: Model API Model API for Declarative Pipeline.
1.1.9
Pipeline: Model Definition An opinionated, declarative Pipeline.
1.1.9
Pipeline: Multibranch Enhances Pipeline plugin to handle branches better by automatically grouping builds from different branches.
2.16
Pipeline: Nodes and Processes Pipeline steps locking agents and workspaces, and running external processes that may survive a Jenkins
restart or slave reconnection.
2.15
Pipeline: REST API Plugin Provides a REST API to access pipeline and pipeline run data.
2.9
Pipeline: SCM Step Adds a Pipeline step to check out or update working sources from various SCMs (version control).
2.5
Pipeline: Shared Groovy Libraries Shared libraries for Pipeline scripts.
2.8
Pipeline: Stage Step Adds the Pipeline step stage to delineate portions of a build.
2.2 Pipeline: Stage Tags Metadata Library plugin for Pipeline stage tag metadata.
1.1.9
Pipeline: Stage View Plugin Pipeline Stage View Plugin.
2.9
Pipeline: Step API API for asynchronous build step primitive.
2.12
Pipeline: Supporting APIs Common utility implementations to build Pipeline Plugin
2.14
Plain Credentials Plugin Allows use of plain strings and files as credentials.
1.4 Pub-Sub "light" Bus A simple Publish-Subscribe light-weight event bus for Jenkins
1.12
Publish Over SSH Send build artifacts over SSH
1.17 Resource Disposer Plugin Dispose resources asynchronously. Utility plugin for resources that require more retries or take a long
time to delete.
0.7
REST API for Blue Ocean This plugin is a part of Blue Ocean UI
1.2.0
REST Implementation for Blue Ocean This plugin is a part of Blue Ocean UI
1.2.0
SCM API Plugin This plugin provides a new enhanced API for interacting with SCM systems.
2.2.1
Script Security Plugin Allows Jenkins administrators to control what in-process scripts can be run by less-privileged users.
1.34
Serenity plugin This plugin publishes Serenity reports which are code coverage, complexity and stability project metrics.
1.2 Server Sent Events (SSE) Gateway Plugin Server Sent Events (SSE) Gateway.
1.15 Shelve Project Plugin This plugin lets you shelve projects so that they can easily be resurrected.
1.5 SonarQube Scanner for Jenkins This plugin allows an easy integration of SonarQube, the open source platform for Continuous
Inspection of code quality.
2.6.1
SSH Credentials Plugin Allows storage of SSH credentials in Jenkins
1.13 Structs Plugin Library plugin for DSL plugins that need names for Jenkins objects.
1.10
Token Macro Plugin This plug-in adds reusable macro expansion capability for other plug-ins to use.
2.3
Variant Plugin This user-invisible library plugin allows other multi-modal plugins to behave differently depending on where they run.
1.1 Web for Blue Ocean Blue Ocean core
1.2.0
Windows Slaves Plugin Allows you to connect to Windows machines and start slave agents on them.
1.3.1
Workspace Cleanup Plugin This plugin deletes the project workspace after a build is finished.
0.34
Any ideas??? I don't even have a clue on where to search for a solution so any help would be welcome.
Thanks,
Milo
There were some crashed pipelines that did not have any status in the overview screen. After deleting the build instances from those jobs (..//build/...) the error went away. Wrong build can be seen by that there are no symlinks to the job.
You'll understand when you go to the corresponding folders :)
Cleanup script:
#!/bin/bash
export BASEFOLDER="/data/jenkins/volumes/tools/web/jobs/"
cd $BASEFOLDER
for folder in */; do
echo "Checking '$folder'..."
cd "${folder}builds" 2>/dev/null || continue
export HIGHEST=`ls | grep -o '[0-9]*' | sort -nr | head -n 1`
echo " Found $HIGHEST. Checking symlink..."
if [ $(find . -maxdepth 1 -lname $HIGHEST | wc -l) -eq 0 ] && [ "$HIGHEST" != "" ]; then
echo " *******************************************"
echo " Missing. Running the command below to fix this:"
echo " rm -rf \"`pwd`/$HIGHEST\""
echo " *******************************************"
rm -rf \"`pwd`/$HIGHEST\"
fi
cd $BASEFOLDER
done
For the Job DSL Plugin (https://github.com/jenkinsci/job-dsl-plugin) you can script your Jenkins jobs using this plugins DSL script with the help of their built in methods to support most plugins.
When you encounter a plugin that is not yet supported you can still use it by using a "Configure" block (https://github.com/jenkinsci/job-dsl-plugin/wiki/The-Configure-Block) that tells the plugin how to build the XML manually.
Is there an equivalent feature for the new Jenkins 2.0 pipeline (https://jenkins.io/solutions/pipeline/) to support plugins that are either not updated often or at least until the plugin author adds support?
You should have a look at new Jenkinsfile capabilities. In essence, you can now configure your entire job using the Jenkinsfile and pipeline approach.
I have a Java project, building with Gradle, using the Jenkins CI server, and I would like to publish to an Artifactory server, using Maven-compatible artifacts. The project is using Git. I would also like to use the release management features of Jenkins if possible.
This is very confusing. There are at least five plugins, with much overlapping redundant functionality. Some plugins seem to replace others. Some plugins seem to require others.
FYI, the five relevant plugins seem to be:
1) Jenkins Artifactory Plugin
https://wiki.jenkins-ci.org/display/JENKINS/Artifactory+Plugin
2) Gradle "maven" Plugin
http://www.gradle.org/docs/current/userguide/maven_plugin.html
3) Gradle "maven-publish" Plugin
http://www.gradle.org/docs/current/userguide/publishing_maven.html
4) Gradle "artifactory" Plugin
https://www.jfrog.com/confluence/display/RTF/Gradle+Artifactory+Plugin
5) Gradle "artifactory-publish" Plugin
http://www.jfrog.com/confluence/display/RTF/Gradle+1.6+Publishing+Artifactory+Plugin
What is the best way to set this up?
If I use the Jenkins Artifactory Plugin with none of the other plugins mentioned, I get an error:
No publish configurations specified for project ':' and the default 'archives' configuration does not exist.
Cannot publish pom for project ':my-great-app' since it does not contain the Maven plugin install task and task ':my-great-app:artifactoryPublish' does not specify a custom pom path.
I assume I need to use either maven or maven-publish in build.gradle?
maven-publish is labeled as the incubating successor to the maven plugin. How much better is it? How stable is it?
How does using one of the Gradle Artifactory plugins compare to the standard maven publishing plugins vs using the Jenkins plugin?
Gradle Artifactory plugins: Gradle can deploy build artifacts and build information directly, without need in CI server by using one of the Artifactory plugins.
artifactory plugin works with maven plugin and publishes configurations, generated by maven plugin.
artifactory-publish plugin works with maven-publish plugin and publishes publications generated by maven-publish plugin.
Jenkins Artifactory plugin works in two modes:
Providing a UI to override settings, specified in artifactory or artifactory-publish plugins in Gradle build script.
Adding and configuring artifactory plugin to the Gradle script if it is not there.
It also provides release management (for both modes).
So, here's what you need to decide:
Whether you use one of the Gradle plugins. Our recommendation is - use it (versioned configuration in build script is an advantage comparing to UI-only configuration.
Which plugin you want to use -- maven or maven-publish. While the later is still 'incubating', it is much more flexible than the former. Once you know with which maven plugin you want to use, select the appropriate artifactory plugin.
You need the Artifactory Jenkins plugin in either way if you want to use the release functionality, just check (or uncheck) the 'Project uses the Artifactory Gradle Plugin' checkbox.
I am using Maven as a build tool and Jenkins as a CI tool. Currently I have a Jenkins job configured with a Maven build step.
I started using SonarQube and was wondering what is the advantage of using the Jenkins SonarQube plugin and configuring the SonarQube analysis as a post-build-action over simply adding sonar:sonar to the goals of my existing Maven build step.
Thanks and best regards,
Ronald
You can save a lot of configuration. So, if you use jenkins sonar plugin you can centralize database credentials and sonar credentials but if you make a decision about execute sonar:sonar in each jenkins job you will configure each with the same credentials.
I just found: Why use sonar plugin for Jenkins rather than simply use maven goal "sonar:sonar"?
And to add one reason: Using the Jenkins SonarQube plugins one can specify "Skip if triggered by SCM Changes". This is nice if you trigger your Jenkins job for each commit but only want to do a SonarQube analysis at a scheduled time, e.g. one per night.
And here is a summary of the the points made by "emelendez":
Centralize database credentials and sonar credentials Use jenkins
Use jenkins sonar plugin configuring SonarRunner for non Java projects
I've just changed to maven-sonar-plugin from the Jenkins SonarQube plugin to avoid divergence of information between the pom.xml and sonar-project.properties.
For example, developers elsewhere had bumped the project version number in the pom.xml, but they don't use the Jenkins builds and didn't care about the sonar-project.properties (or probably understand it). By switching to the maven plugin instead, the project version is defined once and referenced in the sonar property set within the pom.
The downside is that I no longer have the SonarQube link from the project's Jenkins page.
I'm not sure where the responsibility might be for adding this link back for projects using maven-sonar-plugin... The link is "owned" by the Jenkins SonarQube Plugin, but this is not being used here. Meanwhile the maven-sonar-plugin component is integrating with maven not Jenkins.
Something would need to observe the build and extract the SonarQube link which is emitted as a [INFO] ANALYSIS SUCCESSFUL, you can browse http://... line in the log.