Hudson build fails with FATAL: null java.lang.AbstractMethodError - hudson

I've installed Hudson on Ubuntu and I am using the git plugin. The git integration and the simple shell script I execute as the build step appear to be working fine, but I get the following error and the build fails:
FATAL: null
java.lang.AbstractMethodError
at hudson.model.AbstractBuild.getCulprits(AbstractBuild.java:278)
at hudson.model.AbstractBuild.getCulprits(AbstractBuild.java:275)
at hudson.model.AbstractBuild$AbstractRunner.post(AbstractBuild.java:565)
at hudson.model.Run.run(Run.java:1386)
at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
at hudson.model.ResourceController.execute(ResourceController.java:88)
at hudson.model.Executor.run(Executor.java:145)
I have no post-build actions.

I got the same exception, and the reason in my case was an incompatibility when using hudson 2.0.0 and the hudson git plugin 2.0.1.
Either upgrade your hudson server or uninstall the git plugin and manually install the older git plugin version from http://hudson-ci.org/downloads/plugins/git/2.0.0/.

Related

How can I fix this yarn when using daml 1.0.1?

In the process of building the create-daml-app project using daml SDK 1.0.1, I'm running into a yarn error when I do daml codegen js .daml/dist/create-daml-app-0.1.0.dar -o daml.js. It returns
Failure: "yarn install --pure-lockfile" exited with ExitFailure 2
Usage: yarn [options]
yarn: error: no such option: --pure-lockfile
I'm not very familiar with yarn so I'm not sure how to proceed. Can someone point me in the right direction? Thanks!
yarn version: 0.32+git
This error occurs for daml SDK 1.0.0 as well.
This sounds like you probably have cmdtest installed which provides a command called yarn as well but has nothing to do with the yarn package manager. Take a look at the prerequisites at https://docs.daml.com/getting-started/index.html#prerequisites for instructions on how to remove cmdtest and a link to the installation instructions for the yarn package manager.

Error downloading and installing Java JDK in CentOS (FIWARE)

I am trying to configure Cygnus in my FIWARE instance. Following the readthedocs tutorial I execute the following command:
yum install java-1.7.0-openjdk-devel
And the following error is listed:
Loaded plugins: fastestmirror, presto
Setting up Install Process
Loading mirror speeds from cached hostfile
  *base: mirror.gadix.com
  *epel: mirror.airenetworks.es
  *extras: mirror.gadix.com
  *updates: mirror.airenetworks.es
http://repositories.lab.fiware.org/repo/rpm/6/repodata/repomd.xml:
[Errno 14] PYCURL ERROR 22 - "The requested URL returned error: 404 Not Found"
Trying other mirror.
Error: Can not retrieve repository metadata (repomd.xml) for repository: fiware. Please verify your path and try again
Anyone have any idea what it can be and how to solve it? I'm new to Linux environment.
It is working fine for me, please refer to this answer to clean the metadata and try installing again.
RHEL documentation mentions similar commands for OpenJdk devel installation.
or run the following commands and try installing it again:
yum clean all
yum makecache
yum update
Java version was changes in the past and newest Cygnus version (1.12.0 by the time being) uses Java 1.8, so probably you should run:
yum install java-1.8.0-openjdk-devel
I'd recommend to have a look to the RUN statement in Dockerfile. The same procedure used to build the docker container can be done to do local installations of Cygnus.

Mercurial on Jenkins, installing and configuring

I have a Mercurial repository (on Bitbucket) with some code (Java) and I want to do CI builds on a cloud-based Jenkins server (at Jelastic, running on CentOS). My problem is that I haven't been able to do a proper installation of Mercurial on the Jenkins server.
The Jenkins build fails with the following message:
ERROR: Failed to clone https://bitbucket_jenkins_user:some_password#bitbucket.org/repo_owner/my_repository because hg could not be found; check that you've properly configured your Mercurial installation
Setup information
It's a private Mercurial repository, hosted at Bitbucket
In Bitbucket I have set up a Service to trigger the Jenkins build, after a Push has happened
I have defined a specific bitbucket jenkins user in my Mercurial repository, it has only read rights and it logs in using simple https authentication
Jenkins runs on a Tomcat 7, hosted in a Jelastic cloud environment, on CentOS 6
The Mercurial plugin was installed through the Jenkins interface, by Manage plugins
The build is configured as being triggered remotely (by the service defined in Bitbucket)
Build results are the same when started manually and when triggered from a push to the repository
When I first did this I was under the impression that installing the Mercurial plugin in Jenkins would be enough, that it would also install the needed Mercurial binaries to be able to connect to the repository and get the code. I have realized that I was wrong and that on the Manage Jenkins / Configure System page I need to specify my Mercurial installation.
Questions
Is it possible to create a Mercurial installation without ssh access and doing a "yum install mercurial"?
In the Jenkins interface, what can I specify when choosing the "Install Automatically" option?
When defining an installer, I have experimented with the "Extract zip/tar.gz" option, but what can I write as the "Download URL for binary archive"?
Jenkins also offers an installer option of "Run command". What kind of commands could that be, maybe a "yum install ..." or "rpm ..."?
Since my server is cloud based, getting ssh access is a paid add-on which I would prefer to avoid. But if that is my only option I will of course do it, thereby getting access to running commands on the server. However, running "yum install mercurial" on Centos seems to only give the 1.4 version of Mercurial. Current version when I write this is 2.6.3, would I need to download the sources and compile it myself or is it possible to get that as a binary for Centos somewhere?
The Mercurial Plugin page has a section on how to use the Auto Installation options to install Mercurial using ArchLinux packages.
"The plugin supports generic tool auto-installation methods for your Mercurial installation, though it does not publish a catalog of Mercurial versions. For users of Linux machines (with Python preinstalled), you can use ArchLinux packages. For example, in /configure under Mercurial installations, add a Mercurial installation with whatever Name you like, Executable = INSTALLATION/bin/hg, Install automatically, Run Command, Label = linux (if desired to limit this to slaves configured with the same label), Command = [ -d usr ] || wget -q -O - http://www.archlinux.org/packages/extra/i686/mercurial/download/ | xzcat | tar xvf - (or …/x86_64/… for 64-bit slaves), Tool Home = usr, and configure a job with this installation tied to a Linux slave."
see https://wiki.jenkins-ci.org/display/JENKINS/Mercurial+Plugin

Hudson - Install as windows service Initialisation failure

Hudson - Install as Windows Service
I am trying to install hudson build server on a windows xp. Path to the Hudson folder in the E:\Hudson. The Hudson directory contains the hudson.war file. I use the following command to navigate to Hudson dashboard.
java -jar E:\hudon\Hudson.war.
Then I can navigate to http://localhost:8080.
Now the problem is when I try to Install as Windows Service it is thrwoing the below exception.
**Installing a service
[hudsonhome] $ D:\hudsonhome\hudson.exe install
System.Management.ManagementException: Initialization failure
at System.Management.ManagementException.ThrowWithExtendedInfo(ManagementStatus errorCode)
at System.Management.ManagementScope.InitializeGuts(Object o)
at System.Management.ManagementScope.Initialize()
at System.Management.ManagementScope.Connect()
at WMI.WmiRoot..ctor(String machineName)
at WMI.WmiRoot..ctor()
at winsw.WrapperService.Run(String[] _args)
at winsw.WrapperService.Main(String[] args)**
Is there any one who faced the same issue. Why it is throwing such an exception?
The only case of "Initialization failure" I know about (regarding WMI) is when the WMI repository is corrupted: see "Rebuilding WMI Repository".
Your context is a bit different, and the script detailed in the article might not be the right one for you, but before executing any script anyway, it is still worth to check if the WMI repo is corrupted or not, before attempting to rebuild it.

How to deploy on a remote machine using hudson's WAS Builder Plugin?

I have a hudson build server (Windows) that does not have Websphere installed. I created a Hudson node that I connect to via SSH. I also installed the WAS Builder Plugin to run jython scripts on the AIX machine. The job that uses the WAS Builder Plugin is tied to the AIX box.
I run into errors. Does anybody know, whether that setup might work or if a different setup will work for the WAS Builder Plugin?
EDIT:
I get following Error Message:
[test] $ cmd /c call /tmp/hudson9035964108103168395.bat
FATAL: command execution failed
java.io.IOException: cmd: not found
at java.lang.UNIXProcess.fullPath(UNIXProcess.java:372)
at java.lang.UNIXProcess.<init>(UNIXProcess.java:178)
at java.lang.ProcessImpl.start(ProcessImpl.java:114)
at java.lang.ProcessBuilder.start(ProcessBuilder.java:466)
at hudson.Proc$LocalProc.<init>(Proc.java:149)
at hudson.Proc$LocalProc.<init>(Proc.java:121)
at hudson.Launcher$LocalLauncher.launch(Launcher.java:633)
at hudson.Launcher$ProcStarter.start(Launcher.java:268)
at hudson.Launcher$RemoteLaunchCallable.call(Launcher.java:778)
at hudson.Launcher$RemoteLaunchCallable.call(Launcher.java:754)
at hudson.remoting.UserRequest.perform(UserRequest.java:114)
at hudson.remoting.UserRequest.perform(UserRequest.java:48)
at hudson.remoting.Request$2.run(Request.java:270)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:432)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:284)
at java.util.concurrent.FutureTask.run(FutureTask.java:138)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:665)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:690)
at java.lang.Thread.run(Thread.java:810)
Finished: FAILURE
I am wondering whether that plugin can be executed on a slave, especially in my case where the master is on Windows and the slave on AIX.
Check Here Hudson Deploy Websphere Plugin
Why dont you remotely trigger builds on Hudson via the hudsonurl:8080/jobs/jobname/build?token=TOKEN url. That way you dont have to depend on BAT files.
Finally I got it to work. I upgraded the plugin to Version 1.4 and to the newest Hudson server 1.355. That seemed to do the trick.