CI Servers for system simulation - continuous-integration

My group work for a software of simulation for plane. To achieve a faster and easier validation and verification, we decided to introduce continuous integration. But I have no idea which CI servers should we choose.
Our contraintes:
- We need to compile in different machine with different platform( Linux, HP ) in local net and in client's net.
I mean, we need to call different functions in different machine in distance. Some of them will need a authorise
- We prefer a CI servers open source
- The sources are in different languages, C, C++, Java ...
- Support SVN, CVS, Clearcase
- Automated tests and reports
- The tests need different machines working together
I've seen teamcity, it seems well, but it's not open source.

Hudson is for you!
Edit to be more precise about your requirements:
Hudson run on a JVM (standalone service, using Jetty, or on a Tomcat server). Thus, the plateform is not a problem.
Hudson is open-source.
Hudson manages Java projects natively, but you can ask him to compile C, C++ or .Net projects.
Support SVN, CVS natively, and a plugin for Clearcase exist (here).
Automated tests and reports: You will need to implement them, of course, but Hudson will launch them for you. For Java projects, simply use Maven for that!
The tests need different machines working together: Hudson can be launched on several machines (one master, several slaves). Each slave can be hosted by any kinf of machine.

+1 for Hudson.
We are using Hudson together with SVN (version control) and Selenium RC (functional testing).
Very easy to set up, has tons of modules for integration, and very visible to all members of the team, especially if you're using the Hudson Build Monitor Firefox plugin.

I used Jenkins earlier, but now I prefer only TC due to it is great for a lot of purposes.
If you need to work with different platforms, it has great opportunity to install a few build agents with OS specified. Also you're able to install so-called Agent Clouds.
If you need to build your applications per branch — it will be done without any extra-scripting.
A lot of VCSs are supported.
Using Maven you're provided to build even Flex applications, even with running automated test (in case of Windows build agent installed).

Related

Automate Maven Scripts

I have a series of Maven Scripts which are to be run in Linux Platform for doing Reversion and Lableing for my Project. I would like to know what Building Tools i can use to automate the Maven Scripts in the Linux Platform?
Also say suppose I have got some error while doing the Reversioning / Lableing of the code. How can the Automate tools Handle these scenarios.
Please let me know of the effective tools and I would certainly reply back whether those do help me out or not!
I would suggest leveraging a "job" coordinator such as Jenkins or Cruise Control to manage any and all of our automation. Maven is natively supported and understood by these tools. An agent will reside on your server, and do the bidding of your coordinator.
Jenkins is a good solution to automate maven build:
easy to install
easy integration with maven
allow you to automate simple task after build failure/success like sending email
many plugins including this one that allow you to do more complex task after a build failure (or build success)
Any one of this
Jenkins
Hudson
Atlassian bamboo
TeamCity
After using LuntBuild, Jenkins and teamcity I can say without a doubt that TeamCity is by far the superior choice.
I think it's free for a small configuration (3 agents, and up to 10 build configurations).
It very easy to install and configure, compatible with most source control systems.

IDE-independent master build for Continuous Integration in a JEE6 project

SHORT VERSION:
In the context of a JEE6 application: What's the best way to setup an IDE-independent, master build process, in a dedicated build server (for CI / Integration test), while still using an IDE at the developer workstations? Which Java IDE is more suitable to such an approach?
LONG VERSION:
We are building a JSF2/PrimeFaces/EJB3.1 JEE6 application to be deployed on a JBoss application server. We need the EAR, WAR and JAR artefacts to be generated in a dedicated machine using an Ant script and be subject to integration testing in a CI fashion (perhaps using Jenkins).
It is also a requirement that the team will use a Java IDE (one kind only, no extra worries there). As a result, developers will produce their local artefacts for the own testing and development using their own, locally-installed IDE. However, I want the main build script on the build server to be independent of any IDE. If the IDE used by the team cannot accept and integrate closely with an externally provided Ant script this can lead to a situation where the main Ant build script will be different and will have to be maintained and evolved independently. So ideally, I would like the same hand-crafted build script to be used both by the developers' IDEs and the build server. In such a setting, if a developer sees the need to modify the Ant script, the modification reaches through git / svn the CI server and is used for subsequent builds. I am stressing "hand-crafted" since, e.g. in NetBeans case, I don't want to use the Ant build script created automatically from the IDE. See the mind-boggling minutiae one has to deal with in this approach (and which I would rather avoid), here.
Therefore I would like to know which of the major Java IDEs (Eclipse, Netbeans, IntelliJ IDEA, other?) is in your opinion more amenable to accepting an externally provided Ant script as the "project definition" and integrating closely to it (in terms of auto-complete and debug, addition of libraries, etc.). The discussion in this SO article seems relevant but is not quite the same situation as my team won't be using two different IDEs. Finally, I understand that Maven might provide a solution since NetBeans can use Maven-based projects where the Maven pom.xml is the project file and one doesn't have to deal with other IDE-specific artefacts, however there is enough Maven FUD on the web (I don't cite sources as I don't want to sidetrack the discussion) that I don't feel comfortable using it for a major undertaking without any significant prior exposure to it.

TeamCity vs FinalBuilder Pro for Continuous Integration Server

I have seen lots of comparisons for TeamCity vs CCNet, but not much for TeamCity vs FinalBuilder Pro's CI.
Forgive me if I am not comparing apples to apples, I am familiar with TeamCity however the company I work for has already purchased FinalBuilder Pro which has a CI Server included.
I'm hoping to get some comparisons, opinions. If TeamCity does not offer more above FinalBuilder we do not want to have to support two systems.
Thanks in advance.
Here are some features present in TeamCity and unlikely present in FinalBuilder:
True client server-architecture with multiple build agents - TeamCity provides a central point of accessing and managing all of your build agents. Build agents can be enabled/disabled/restarted from single Web-UI, you can also view logs or view thread dumps of builds running on different build agents.
Support of Amazon EC for build agents grid
Pre-tested commit and remote run features (no more broken code in VCS. Well, almost :)
Integration with Visual Studio and other IDEs - a dedicated plugin for that
Extensible reporting, you can include your own HTML-based reports into build results
Comments/Pin/Tags for builds
Cross-build search
Integrated code coverage and duplicates finder for Java and .NET
FinalBuilder has support of some VCS systems, which are not supported by TeamCity, though.
Disclaimer: I'm one of TeamCity developers.
We are using TeamCity for the build orchestration, but using FinalBuilder to actually carry out the individual builds.
I love FinalBuilder for the ease of scripting and maintainability, but I also love TeamCity for all the points in KIR's answer.
In our setup, each TeamCity buildconfig is configured to use the commandline runner, and finalbuilder's fbcmd.exe is invoked with the name of a script to run.
All sweetness and light.
I have done a comparison of the 2 products for a continuous integration talk in the Uk - basically my findings were that TeamCity was more intuitive to use. FinalBuilder seemed to me to be ambigious in its language and seemed to be clunky to set up builds
Once the work was done it was a very good system - but for me TeamCity was much more intuitive and had a better user experience than Final Builder
this is very subjective though - each tool is very good. It comes down to what you are comfortable with and I was much more comfortable with TeamCity

What's the workflow of Continuous Integration With Hudson?

I am referred to Hudson today.
I have heard about continuous integration before, but I have no idea what the heck is a ci-server.
Hudson is really easy to install in Ubuntu and in several minutes I managed to set up an instance of it.
But I don't quite understand the workflow of a ci-server, or how am I supposed to use it?
Please tell me if you have experience about ci, thanks in advance.
Edit:
I am currently using Mercurial as my SCM, and I wonder what is the right way to use it with Hudson.
I have installed the Mercurial Plugin of Hudson, and I create a new job with a local repository. When I commit in the repository the Hudson job is built with the latest version of my source code.
If what I used is a remote repository, what's the workflow like?
Is it something like the following?
Set up a Hudson job with the repository
Developer makes a local clone of the repository
Developer commit and push changes
The remote repository update with the incoming changeset
Run a Hudson build
There may be something I misunderstanded at all, please help me point it out.
Continuous Integration is the process of "integrating software" continuously i.e. as frequently as possible (ultimately after each set of changes) to avoid any big-bang integration and all subsequent problems by getting immediate feedback.
To implement Continuous Integration, you first need to automate the build of your software (where build means of course compiling sources, packaging them, but also compiling tests, running the tests, running quality checks, etc, anything that will help to get feedback on the health of your code). Then you need to trigger the build on the latest version of the sources on a particular event (a change in the repository, a temporal event), to generate reports and to send notifications upon failure (by mail, twitter, etc).
And this is precisely the responsibility of a CI engine: offering trigger mechanisms, being able to get the latest version of the sources, running the build, generating and publishing reports, sending notifications. CI engines do implement this.
And because running a build is CPU and Disk intensive, CI engines usually run on a dedicated machine (or even a farm of machines if you want to build lots of projects).
Back to your question now. Once you've got Hudson running, configure it (Manage Hudson > Configure System): setup the JDK, build tools, etc. Then setup an Hudson Job and follow the steps: configure the location of the source repository, the build tool, the trigger, a notification channel and you're done (you can do more complex things but that's a start).
For more details on the setup, check:
The official Use Hudson guide for more details. << START HERE
Continuous Integration with Hudson - Tutorial.
Spot defects early with Continuous Integration.
Martin Fowler's overview of continuous integration is one of the canonical references. In my opinion, using automation to make sure your code base is healthy is one of the most useful things that you can set up.
Update Sorry that I didn't have much time earlier to expand on my reply. #Pascal_Thivent is right that in order to effectively use CI, you need to be able to automate your builds, tests, etc. CI is actually a good forcing function for this. For me, it's one of those little warning flags if I start to think that it would be too painful to put a build into Hudson. It means that something is not quite right.
What I like about Hudson is that it's flexible enough to accommodate different workflows. We use it for both builds / unit tests and releases. And it eliminates a lot of the worry about certain release procedures only working in one person's environment.
What I don't like about Hudson is that it is occasionally unstable when new builds break plugins. I've had a couple of upgrades (2 out of 10 or so) go bad because of incompatibilities. I do two things now:
I never upgrade my team's Hudson server to the latest and greatest right away. I generally only upgrade when there are significant new features, or bug fixes.
I now have a basic Hudson instance set up with all my plugins on a virtual machine with some dummy builds that I fire up to test out any new upgrades before doing it on the public server.

Infrastructure required for TDD?

I am 'relatively new' to unit-testing and TDD. Only more recently have I completed my first production application that has (at least in theory) 100% code coverage. I have done unit-testing in previous projects as well for some time, but not in true TDD fashion and with good code coverage. It had always been an after-thought. I feel I have a pretty good grasp on it now though.
I'm also trying to train the rest of the team on TDD and unit testing so that we can grow togeather and start moving forward with doing unit testing in all of our applications, and eventually progress to doing full TDD w/ automated builds & continous integration. I posted a thread here regarding my plan of attack / training agenda for comments & critisism.
One of the replies (in fact the highest voted) suggested I first setup infrastructure before I go forward with the training. Unfortunately I have no exposure to this, and googling on the topics is difficult because the pages for CruiseControl.NET / nAnt / etc do not really explain the 'why' we should set this up and the 'how' everything connects togeather.
We are a small shop (about 10 developers) and use almost exclusively microsoft technologies and do our development in VB.NET. We are looking to eventually start using C# but that's for another time. I've been using the MSTest project that comes with VS2008 for my unit tests, and I've been building my apps using Visual Studio, and deploying using MSI setup projects... We also (unfortunately) use VSS for our soure control - but that is also on the chopping block and I'd really like to get rid of it and use subversion.
I know that I need to use CruiseControl.NET for CI, and either nAnt or MSBuild for building the applications. And I probably need a build server to run all these builds. But I just can't find anything that 'connects' the dots and explains how they interact with eachother, what should be on your build server, when you should build with your build server (is it just for deployment builds, or even when you just want to compile the app you're developing after making a small change, on your local environment?). I'm also planning on axing MSTest as I've found it to be buggy and will use nUnit instead.
Can anyone perhaps illuminate this gap I have from 'knowing how to do TDD' to 'setting up the proper infrastructure so the whole team can do it and work togeather'? I do understand what continous integration is, but again, I'm not sure how a build server should be setup and how it connects with everything, and why we need one (e.g. the pitch to management).
thanks very much for your time.
What portion of finalbuilder do I need? It seems there's some overlap with final builder and teamcity. Finalbuilder server seems to be a CI server, so I'm guessing I don't need that. FinalBuilder seems to be a build server - but I thought TeamCity is also a build server... And Automise seems to be a visual windows automation tool, like some kind of development platform for winforms apps...
_I also don't see support for final builder in The Team City Supported Apps Diagram : _
Take a look at a webinar I did a few weeks ago - How To Start Unit Testing Successfully. In that webinar I've talked about tools and unit testing best practices and it was aimed at developers just like you who want to introduce unit testing in their organization.
First order of business you want to put a CI (Continuous Integration) process in place and for that you'll need three tools:
Source control
Build server
Build client/script
I hope you already have some form of source control in place so let's talk about the other two.
Build Server - checks the source control and when it changes (or some other condition met) runs a build script on some client (or same machine) there are several build server available I recommend JetBrain's TeamCity it's easy to install and use (great web interface) and is free for up to 20 developers (that's you).
Build Script - on your build client you want to run a build script that would build your solution and run your unit tests. TeamCity has some basic build & test capabilities but for more advanced options (build installer, documentation etc.) you'll need some script runner at work we use FinalBuilder - it's not free but has very good editor. If you're looking for a free alternative have a look at ANT or NANT - but be prepared to edit a lot of XML.
Other tools - Because an important part of successful unit testing is how easy it is to write and run tests on the developer's machines I suggest you check if there are better IDE's or external tools that would help the developers write & run their unit tests.

Resources