I am starting a project from scratch using Intersystems Cache. I would like to setup a Continuous Integration Server for the project. Cache has unit test libraries, so the idea is to import source into a test database, build the source, run unit tests in the cache terminal, based on changes in the version control system (ClearCase).
Apart from Cache Objectscript, there will definitely be some java code that needs to be built as well. Other technologies could be added later. So I need a Continuous Integration tool that is not bound to one specific technology and that is easily extendible. I have used CruiseControl for building java solutions in the past, but that has been quite some time ago and I am wondering if no better solution is available since.
What is the best (and hopefully free) Continuous Integration product, that is easiest to extend for different technologies?
I'd recommend looking at Hudson. It's insanely easy to try out as it is delivered as an executable jar. It also supports plugins so it may be better suited to extension and customization. There are also a good deal of very handy plugins for Hudson already out there. Its ClearCase support comes via a plugin. There's even a plugin to start and stop VMWare virtual machines from within your build process which may be of interest depending on how you're planning on handling your database server "needs."
I have built a makeshift Continuous Integration Server in the following screencast: http://www.ensemblisms.com/episodes/2
Raymond Roestenburg!!
I am currently testing a stack for continuous integration of our solution is developed in Caché , the stack I'm testing now includes versioning source code using Git + TortoiseGit (with a plugin called "cache-tort-git "https://github.com/intersystems-ru/cache-tort-git/wiki specific to Caché ) for local versioning and BitBucket for remote versioning.
For continuous integration I'm using the Jenkins (evolution of the Hudson) , with a job that downloads the updated source code and after runs a COS script that does the following tasks:
Compiles all the source code;
Compiles all CSP rules;
Compiles all CSP pages;
Run all unit tests;
Run all integration tests;
Related
I'm running a data mining program using IntelliJ on my computer, but I need to run the program on a server for its larger memory and faster CPU.
My current work flow is: Write code on laptop => push code to github => pull code from github on server => compile and debug. I found myself wasting a lot of time during the development.
Is there a way to get my code written and compiled locally on IntelliJ(or Eclipse) and pushed to server for running directly?
In general terms, what you need to do is:
Install the Intellij plugin associated with your application server.
Create a run configuration associated with your app.
Build/deploy/debug and refine.
The secret sauce is #2 and is what #Jagermeister is alluding to. From there you can do a plain IDE build, maven goals, ant tasks, or any external tool you care to configure.
The main thing you need to do is find the most efficient way to integrate your build workflow with Intellij. If you're using simple IDE builds (what Intellij unfortunately calls "Make"), Intellij has built-in facilities for deploying "exploded" artifacts (non-archived), which allows for extremely rapid debugging via "hot-swapping" of modified classes.
All of this is in the docs.
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 10 years ago.
Anyone out there have experience with both Hudson and Bamboo? Any thoughts on the relative strengths and weaknesses of these products?
Okay, since folks keep mentioning other CI products I'll open this up further. Here are my general problem. I want to setup a CI system for a new project. This project will likely have Java components (WARs and JARs), some python modules, and possibly even a .NET component. So I want a CI server that can:
Handle multiple languages,
Deploy artifacts to servers (i.e. deploy the war if all the unit tests pass.)
I would also like something that integrated with a decent code coverage tool.
Good looking reports are nice, but not essential.
Multiple notification mechanisms when things go wrong.
I'm not worried about hosting. I'll either run it on a local server or on an Amazon instance.
Also, this maybe pie in the sky, but is there something that can also build iPhone apps?
Disclaimer: I work on Bamboo and therefore I am not going to comment on features of other CI products since my experience with them is limited.
To answer your specific requirements:
Handle multiple languages
Bamboo has out of the box support for multiple languages. Customers use it with Java, .Net, PHP, JavaScript etc. That being said, most build servers are generic enough to at least execute a script that can kick off your build process.
Deploy artifacts to servers (i.e. deploy the war if all the unit tests pass.)
Bamboo 2.7 supports Build Stages, which allow you to break up your build into a Unit Test Stage and a Deploy Stage. Only if the Unit Test Stage succeeds, the build will move on to the Deploy Stage. In Bamboo 3.0 we will support Artifact sharing between stages, allowing you to create an Artifact (e.g. your war) in the first Stage and use this Artifact in the following Stages for testing and deployment.
I would also like something that integrated with a decent code coverage tool.
Bamboo comes with support for Clover and also has a plugin available for Cobertura.
Good looking reports are nice, but not essential.
Bamboo has a whole bunch of reports which are nice, but not essential :)
Multiple notification mechanisms when things go wrong.
Bamboo can notify you via email, RSS, IM, an IDE plugin or a nice wallboard that is visible to the whole team.
I'm not worried about hosting. I'll either run it on a local server or on an Amazon instance.
From experience, it is generally cheaper to host your own CI server. But if you need to scale, Bamboo makes it easy to distribute your builds to additional local agents or scale out to Amazon via Elastic agents.
Also, this maybe pie in the sky, but is there something that can also build IPhone apps?
Similar to the answer to your first question, most CI servers will be able to build iPhone apps in some ways. It's possible that there is a little more scripting required though.
Price: Bamboo is not free(apart from our free starter license)/libre/open-source, but you will get Bamboo's source-code if you purchase a commercial license and full support. Compared to the cost of computing power and potential maintenance required for a CI server, the cost of a Bamboo license is rather small.
Hope this helps.
I have not used Bamboo but I have used Hudson, Cruise and TFS and out of all of them Hudson was hands down the best. It is ridiculously easy to set up and has a really nice web GUI for project configuration. What is great about Hudson is that it supports pretty much any language and feature you could want assuming someone has written a plug-in for it, which they probably have.
http://wiki.hudson-ci.org/display/HUDSON/Plugins
We used it to run .NET, Java and C++ builds on timed intervals as well as SVN checkins with automated test harnesses and it was great. The place before last I worked at started some iPhone development just before I left and I believe they were using Hudson for that too.
Plus it's free!
Bamboo vs Hudson, at a very superficial level, seems to come down to:
Bamboo: Easy to use and good looking
Jenkins: Rough around the edges, but is far more flexible than Bamboo
Both Bamboo and Jenkins have numerous bugs (you will run into problems) but at least with Jenkins you are much more likely to have a workaround until it's fixed. With Bamboo, you're stuck waiting for an update.
Disclaimer: I'm working with Jenkins.
In our organization (quite big, more than 100 developers), we found also these two features very useful:
CAS plugin with matrix project security strategy
Build Pipeline Plugin
LTS release schedule.
About your questions:
OK
SCP PLUGIN or SSH PLUGIN
We use FINDBUGS, Static Analysis Collector Plug-in, Static Code Analysis Plug-ins, Task Scanner Plugin
Previous at point 3 + Jenkins DocLinks plugin
We use email Jenkins Email Extension Plugin, but it supports also other systems, like rss, twitter publish, sms...
We are running in a Tomcat Hosting, Locally.
Yes.
Well, I haven't used Bamboo so far, but one difference is that Hudson is free/libre/open-source software.
If you're willing to pay for it, Anthill does all of these you're looking at. We use it at my firm for our web team, and it's pretty powerful.
Handle multiple languages
Out of the box, it automates your existing scripts and manages the artifacts they produce no matter what language.
Deploy artifacts to servers (i.e. deploy the war if all the unit tests pass.)
Deployment can be added as a step in your build process. I'm not sure you'd want to deploy directly to production, but you certainly could if management says you have to.
I would also like something that integrated with a decent code coverage tool.
They integrate out of the box with Clover, Cobertura, Emma, Checkstyle, CodeSonar, Coverity, FindBugs, Fortify, Klocwork, PMD and Sonar.
Good looking reports are nice, but not essential.
I'm not sure what reports are available but there is a reports tab (I don't go in there :-) )
Multiple notification mechanisms when things go wrong.
I know it can do email (and therefore sms), integrates with a few IM services.
I'm not worried about hosting. I'll either run it on a local server or on an Amazon instance.
I saw a demo of them firing up a cloud session from an image, complete with an agent for deployment. We run it on a typical Linux box, but I know some folks run it on a VMWare server.
Also, this maybe pie in the sky, but is there something that can also build IPhone apps?
This would fall under the first one, probably.
I'm trying to find a practical unit testing framework for JSF.
I know about JSFUnit, but this is very impractical to me. I need to include about 10 JARs to my project, and jump through many other hoops just to get it running.
I realize that -- due to the need to simulate a platform and a client -- unit testing web applications is difficult. But is there a better way?
Have you thought about doing integration testing with Selenium or another tool? Selenium allows you to record and run tests directly in the browser. You can also run tests in multiple browsers and on multiple platforms with Selenium Remote Control.
Writing unit tests is good, but it might provide more to create some functional integration tests rather than unit-testing the presentation layer code.
On the project I'm working on at the moment we dabbled with using selenium. We actually spent a lot of time writing these selenium tests, but found that they added little value because the UI changes so much and you just end up doubling your effort for very little return on investment.
Another problem with selenium is that it requires your code to be deployed, which means it doesn't play well with unit test frameworks eg maven.
What I would say is that writing really good unit tests for your managed beans is invaluable.
Have you taken a look at the jsfunitwar Ant task or alternatively the Maven plugin provided by JSFUnit? Both greatly reduce the complexity of generating the .war file to be tested. I'm using JSFUnit on my current project and find the combination of white box and black box testing capabilities to be very powerful. Because JSFUnit uses HtmlUnit under the covers, you can very easily and effectively examine the generated HTML, or conversely, verify the state of your internal JSF backing beans. I was able to incorporate the JSFUnit tests into my Continuous Integration process and have been quite pleased with the outcome.
HttpUnit can also be an alternative. It provides apis so you have a choice to automate the tests.
http://httpunit.sourceforge.net/index.html
Selenium is superficial, jsfunit is inward. I recommend that use jsfunit if project is not simple. Because team member can change jsf managedbean names or etc, you can catch that with jsfunit.
I'm with Paul on Selenium being very easy to setup and start working with. I use Selenium IDE in Firefox with some customization at that level, then you can export these to other platforms such as Java JUnit tests. It was quite easy to download and launch the selenium-server.jar, add the selenium-java-client-driver to my existing Eclipse Maven POM driver project; then launch the same exported JUnit test in Eclipse. I mainly wanted to use Java just for looping which the basic Selenium IDE didn't support.
I have configured JSF Unit for my project too which does require more time to configure... more importantly though with in-container tests like JSFUnit changes to the test require rebuilding the WAR, redeploying in the container and then executing from Eclipse or via a browser. So for quickly trying a small change this is time consuming. Of course with JSFUnit you have access to all the internals of the JSFSession etc so it depends what granularity of testing you need I guess.
I'd be interested if anybody knows a faster way to turnaround changes to a JSFUnit test and execute it. Definitely Selenium tests feel more like JUnit tests in that regard.
We're migrating our application into a Java EE container, and looking for tools to use for unit testing (and integration testing) our migrated app.
Our requirements include:
Ad-hoc testing: the ability to run tests manually, on demand (to be used by developers while developing code)
Batch testing: the ability to run a large (and growing) set of tests regularly
In-Container: integration tests that use EJBs as they are deployed in the container
Unit testing: Testing of classes not necessarily inside an EJB context
Nice to have: Simple to set up, integrates with ant/IDE
No requirement to test Servlets/JSPs - only POJOs and EJBs
What are you using to achieve testing in Java EE environment? What technologies/setup have you deployed?
My research have uncovered Cactus and JUnitEE: have you had success setting them up?
We use normal JUnit for both unit tests and integration testing. We switch between the two using a VM argument, and have the tests annotated with markers for direct vs. server. We do have a custom TestSuite class though that finds and runs the tests based on this information, as it was easier and less error prone than manually maintaining which tests to run.
In our case we use Spring remoting to talk to servlets and EJB's (via the servlets), and testing both cases is simply a separate launch configuration within Eclipse.
We used JunitEE a few years ago, but eventually gave up on it in favor of just using JUnit throughout. This enabled us to have developers do all their testing without a server at all and run both unit and what I would call low level integration tests in their IDE. Then we let the build machine run the same integration tests against the same code now deployed in the actual server. This makes the development cycle much faster as we rarely need to run the server and deploy service code.
JUnit(EE) is what every major project($100mil+) I've supported has used. It's really a fantastic tool and knowing how to use it is invaluable when/if you decide to look for other job opportunities.
I supported a government financial system that used no unit testing but after a lot of pushing we finally implemented JUnit. The system I work on now is a large government agency modernization and we use JUnit for all of our unit testing. The two large firms supporting the modernization have essential made JUnit the standard across all of the sub projects. We've got ~200 developers using it without a hitch.
It's quick and easy to set up and once you understand it and you can leverage the features it will demonstrate how invaluable it is.
We're in an early stage of a new web project. The project will grow and become complex over time. From the beginning we will have unit and integration tests using JUnit and system tests using HtmlUnit. We might also add some static code analysis tools to the build process if they prove to be of value to us.
If you're or have been involved in a project which uses continuous integration. Which software do/did you use and do you think it has payed off? Which software would you recommend for continuous integration of a Java web project?
Hudson (the best). Hudson Website
JetBrains TeamCity Pro. http://www.jetbrains.com/teamcity/index.html
The Professional Edition does not require any license key. TeamCity starts running automatically with the Professional Edition Server if no license key is entered in the program. A single Professional Edition Server installation grants the rights to setup:
3 Build Agents at no additional cost
20 User Accounts
20 Build Configurations
Having used both CruiseControl and Hudson , I can recommend Hudson as the easier of the two to config (easily done via the web GUI, though direct configfile editing is also supported).
Hudson is great and free:
http://hudson.dev.java.net/
Bamboo is great but costs $$
http://www.atlassian.com/software/bamboo/
I've been very pleased with Atlassian's Bamboo. Even though it is commercial, the Starter Pack license is just $10 for 10 users. It's very well documented, easy to set up and flexible.
CruiseControl works reasonably well once you get it configured.
http://cruisecontrol.sourceforge.net/
I've used CruiseControl for Java projects, and CruiseControl.NET for .NET projects, and both work great.
I setup CruiseControl for a project that's been running for 4 years with several dozen developers, and while the configuration has been tweaked several times in the interim, it works great. (I don't actively support that project anymore, but I still work with the people who do.)
In my current position, CruiseControl.NET is being used to support several .Net projects, and has been used for 2+ years.
CruiseControl
CruiseControl is both a continuous integration tool and an extensible framework for creating a custom continuous build process. It includes dozens of plugins for a variety of source controls, build technologies, and notifications schemes including email and instant messaging. A web interface provides details of the current and previous builds. And the standard CruiseControl distribution is augmented through a rich selection of 3rd Party Tools.