Recently, I was tweaking MultiSPI to add the following class loading fallback logic:
if (threadContextLoader != null) {
loadFromContextLoader(className);
} else if (systemLoader != null) {
loadFromSystemLoader(className);
} else {
loadFromBootstrapLoader(className);
}
and realized that it’s not immediately evident how to do this in a uniform way. But actually, it’s quite simple…getting a ClassLoader object for the bootstrap loader is just a couple of lines of code.
(more…)
Tags: class loader, Java
Filed under Java, Tools | No Comments »
Implementing a Java SPI isn’t a particularly 2011 experience1. Creating a correctly-named text file in META-INF/services, making sure it is correctly packaged and remembering to keep it up to date when you refactor is sufficiently annoying and error-prone that there are at least a couple of utils that aim to make this easier.
At XebiaLabs, however, we’re not just the implementors of our plugin SPI. We also write the deployment engine that consumes these plugins. And unfortunately, there isn’t much out there to help you read, load and verify services. Hence MultiSPI.
(more…)
Tags: dependency injection, Java, spi
Filed under Java, Tools | No Comments »
We’ve been busy for a couple of weeks now refactoring a fairly complex code base of just under 500 classes. None of us really knew all the details about this part of the system, but we didn’t let that stop us of course. After some regrouping/-shuffling/-factoring/*ing, the whole thing built OK and all unit tests were green again. All that was left to do was fix the Fitnesse tests. I remember thinking this should be easy since we had all those green unit test.
Evil laughter sounds.
(more…)
Filed under General, Testing, Tools | 2 Comments »
Last week (november 3rd) Andrew Phillips and myself did a presentation on continuous deployment at the awful (so we thought) hour of 8 o’clock in the morning for the NLJUG. We only expected a handful of attendees but fortunately the day before we were told that we had moved to a bigger conference room because of the great number of people signing up! So at 8 o’clock we had about <100 people in the room! So, if you were there, thanks for coming so early, we really appreciate it. It of-course shows that continuous deployment is a hot topic
Filed under Deployment, Middleware, Tools, Xebia Labs | 1 Comment »
Contrary to what you might have expected because of the title, this is not an introduction to the marvelous UNIX hexdump tool. If that’s what you were searching for, then you better pull up the man page first, because I’m not going to spend a word it. This article is about something better…
Filed under Java, Tools | 2 Comments »
Last week we had one of our infamous tech rallies and we had a lot of fun trying to build our own Posterous clone in a day, i.e. turning emails into blog posts.
The project sources are hosted on Github. We were working on this one-day project with about 20 developers spread over 4 teams and one of the things I noticed is that most of us did not have more than the very basic Git experience. This meant that we ran into a lot of merge conflicts and solving those is not always easy. Below is a little rundown of the Git learning stages we went through in team MongoDB to deal with this.
Tags: GIT, knowlege-exchange, techrally
Filed under Fun, General, Tools | 12 Comments »
Recently, Andrew Phillips, VP of Product Management at XebiaLabs, and I had the opportunity to speak with Mike Vizard, tech journalist for IT Business Edge. We had a great conversation about automating application deployments and Mike’s article provides a nice look into our discussion.
(more…)
Tags: best practices, deployment automation, IT workflow
Filed under Deployment, General, Middleware, Process, Tools, Xebia Labs | 1 Comment »
Virtualization and cloud computing have exploded over the past few years. A recent study shows that 90 percent of businesses have implemented server virtualization at some level and Gartner estimates the current market for cloud services is $46.4 billion and will reach $150.1 billion by 2013. With other estimates saying business applications can be made three to five times less expensive and consumer applications five to ten times cheaper, it’s no wonder it’s taking off.
Among other benefits, virtualization and cloud computing are helping companies remove physical dependencies from network resources, respond faster to changing IT-infrastructure needs, and lower overall costs. While this is all well and good, as companies add more and more virtual resources to their network, they struggle to keep track of them. The reason? Virtual sprawl.
(more…)
Tags: cloud, Deployit, Deployment, deployment automation, Virtualization, Xebia Labs
Filed under Architecture, Cloud, Deployment, General, Middleware, Tools, Virtualization, Xebia Labs | No Comments »
When running Selenium tests from JUnit it’s very useful to be able to capture screenshots when something fails. Especially when you run it in a Continuous Integration environment which you aren’t monitoring. A screenshot combined with the stacktrace makes identifying and fixing the error easier. When you combine this with a JUnit @Rule you can make it transparant and use it for every testcase (more…)
Filed under Java, Testing, Tools | 3 Comments »
Git has made me more productive, and I will explain in a few words why that is. I could almost do it with twitter, but I like to take a little more time to make my point. The main benefit that git has given me can be found in performance of certain things I want to do when I am managing changes in my code base. The performance improvements of some critical parts of it are even so profound that they have changed the way I am working. In particular the fact that I can skip builds for most of my commits is a big time saver.
There have been many things said about git already and I suggest you use your favorite search index to bring yourself up to speed if you need to. Git is a simple distributed versioning system that is challenging many assumptions I had about development. Let’s go over these assumptions. I’ll show you my (svn based) assumption and why it doesn’t hold if you’re using git.
(more…)
Tags: GIT
Filed under Java, Tools | 6 Comments »