An Interview With the Guys at Alfresco

Henrik Paul
On May 5, 2011 6:36:00 AM

Recently, some of us at Vaadin HQ have been dabbling in Activiti. Thus, when it came to our attention that Alfresco, the company behind Activiti, is taking Vaadin very seriously, and are rewriting a whole lot of their stuff to use Vaadin, this naturally piqued our interest. Wanting to dig deeper, we set up an interview with the guys working on Activiti.

Hi. Could you tell us with a few words who you are, what do you do with Activiti?

Joram: Hi, my name is Joram Barrez. I’m a software engineer at Alfresco working on the Activti platform from my comfy desk at the heart of Belgium. Before Alfresco, I worked at JBoss/Red Hat on the jBPM project, so I’ve been doing open-source BPM in java for quite some time now. My current area of expertise revolves around BPMN 2.0 (a standard on how to describe business processes), and lately I’ve been involved in building the new user interface for Activiti.

Frederik: Hi, I’m Frederik Heremans, a Belgium-based software engineer at Alfresco. I joined the Activiti team in August 2010. The years before that, I worked as Java and ECM consultant for various clients. After I worked some time on the integration of the Activiti engine into the Alfresco repository, I’ve also been involved in building the new UI using Vaadin.

How would you describe Activiti in a nutshell? What does it do and for whom is it?

Joram: Activiti is a lightweight Java framework to execute BPMN 2.0 business processes. Such business processes are basically a sequence of steps that involve automatic and human tasks. Using a visual process to describe what you’re actually doing drastically improves communication between (and the overall happiness of) developers and business people.

Unlike our competition, we have a clear focus on developers and we always make sure that doing Business Process Management (BPM) with Activiti is fun!

Where does Vaadin come into the picture? What part of Activiti is done with Vaadin?

Frederik: There are actually two tracks where Vaadin comes into the picture. When you download Activiti from, you get of course the jar library but we also include some webapps that cover the basic functions of a BPM system such as starting a process, seeing your current tasks, uploading new versions of your processes, etc. So the first track is the replacement of these existing webapps with a Vaadin-based webapp.

Joram: We’re currently also looking into options to run Activiti on the cloud with an elastic back-end. Obviously we need a great UI for that, and Vaadin is a perfect fit.

Could you tell a bit about the process that ended you up with Vaadin? What other technologies did you try before Vaadin and what were your requirements for the technology you were looking for?

Joram: As with any development team, our main requirement was productivity. And it had to look like the prettiest thing you’ve ever seen, of course ;-)

Our ‘old’ webapps use javascript + REST for the UI. The biggest problem for us is that first of all the productivity of coding in Javascript is simply not high enough to deliver fast and deliver often. You could blame that on our lack of javascript-guruness, but the point is that Vaadin does allow us to go extremely fast, without having to learn a gazillion of new frameworks.

Secondly, we tend to refactor a lot. And I do mean *a lot* (I’m looking at you, Tom ;-). The fact that Vaadin is 100% Java makes it a breeze to roll out refactoring through all layers. Especially in a team like ours, where the members are spread across the globe and not everyone is involved in all aspects of the software this is crucial.

The process how we ended up with Vaadin is quite a funny one. I remembered reading about Vaadin for the first time, around the time of the name change from IT Mill to Vaadin. But it wasn’t until I met the Vaadin guys at Devoxx in Antwerp last year, that I was really convinced. After some tech talk, they wanted to give me the printed version of the Vaadin book. However, no more copies were left. I did leave my contact details with one of the developers. So to my big surprise a few weeks later, a big package from Finland arrived … containing ten Vaadin books and a personal note apologizing for not having enough books at Devoxx. How awesome is that! I thought: these guys must really create an awesome framework if they’re doing these kind of community effort. So I started doing some Vaadin coding and before I knew it, I wrote a new component for the Activiti platform, called Activiti Kickstart, using Vaadin and JAXB to create business processes using a very simple but easy to use UI. From that moment on, I was hooked.

How does the productivity feel like when working with Vaadin? How does it compare to some of the other products you have tried with Activiti?

Joram: Productivity is sky-rocketing. We are estimating in hours again, instead of days. I’ve seen my share of UI frameworks (Struts, JSF, GWT, etc.), but none comes close regarding productivity. And I’ve never liked HTML and Javascript at all, so I’m happy that Vaadin takes care of that for me.

Frederik: Besides Vaadin, we are also using JRebel. JRebel reloads classes on fly whenever you do a change in your IDE. Since in Vaadin, everything is a class, this works brilliantly. On an average day, we only have to redeploy four or five times (when changing a superclass, JRebel can’t handle that yet). Seeing instant results of our changes allows us to move at an extremely fast pace.

What other technologies are you using together with Vaadin?

Activiti + Spring + Vaadin is the stack we’re currently using. And Maven2 as build tool.

Do you have a neat trick or pattern you've discovered that you'd like to share with new Vaadin developers? Something that every Vaadin developer simply must know.

Joram: When you’re doing the general layouting of your app, the ‘debug’ mode is a life-saver. Just add ‘?debug’ to your url and you can inspect the whole component tree and find nasty little layouting bugs quickly.

I would also seriously recommend getting a JRebel licence and a Vaadin Pro Account. Both are really worth the money. Especially Vaadin Testbench is crucial if you want to deliver quality software. For those that don’t know Testbench: it’s basically a selenium completely tailored to Vaadin. The results of the Selenium recording can be stored as a JUnit test, and run on multiple platforms in the QA environment. Really awesome.

What has been the most challenging thing when developing Activiti with Vaadin? How did you solve it?

Joram: In the beginning, I struggled a lot with getting the widths and heights of a component the way I wanted them to be. For some reason, some components disappeared or were put in places I didn’t expect them to be. In Vaadin, you have to make sure that your parent component has a defined size, if you want the children to have a defined size. Sounds easy, but in practice it leads to a lot of frustration. Luckily, after a while you learn where to take special care and how certain out-of-the-box components behave. Looking back, it is only a small nuisance, but I remember that Frederik had similar frustrations when he learned Vaadin.

Frederik: That’s right, it took some time to get a grip on the sizing and layout. But once you get the hang of it, you just do it right the first time... Another thing I found challenging was applying a pure HTML+CSS design on our existing Vaadin-app. Not that the Vaadin-components aren’t easy to style (actually, quite the opposite). The design was created based on a photoshop mock-up, created by HTML and CSS guru’s who did their best to use all the tricks in the book to make the design look awesome. It took me some time to convert all of the styles to behave the way Vaadin expects it, but this process also gave me more insight on how Vaadin handles padding, and spacing in it’s layouts. Luckily, very complete documentation and some good examples are available on Vaadin’s website (for example, styling buttons using images made easy thanks to css-extract on forum).

Considering the experiences you've had with Vaadin thus far, what are your thoughts regarding the use of Vaadin in the future?

Joram: I truly believe Vaadin will get a spot in each Java developers framework-belt. I’m using it currently for each of my professional and personal projects, and a lot of people I meet get a Vaadin-brainwashing session for free. I confess: I’m addicted to Vaadin.

Frederik: When Joram talked to me about Vaadin, I was a bit sceptical at first (yet another UI-framework?) but my doubts soon disappeared when I actually started using it, it just works!

I'd like to thank both Frederik and Joram for the time they took to answer the questions, and wish a lot of success with their Vaadin rewrite!

Henrik Paul
Henrik Paul works as a Scrum Master at Vaadin's product development. He has been working at Vaadin since 2008 with basically anything and everything, except in sales or administration. He's one of those annoying guys who is never satisfied with the status quo, and questions established practices constantly.
Other posts by Henrik Paul