This is not a tag line!
technology
Improving deployment of WSRP-related artifacts in GateIn
Mar 9th
As you may know, I am working on WSRP for GateIn. One problem I faced until today in my daily development was that deploying a new version of the WSRP module for testing required re-building GateIn completely, which takes quite a bit of time and has the side effect of also destroying any persisted data. This, in turn, resulted in even more wasted time spent on configuring GateIn so that I could perform my tests (configuring consumers, adding remote portlets to pages, etc).
I decided that I could make that process faster by just replacing the WSRP artifacts in an already built version of GateIn if there hadn’t been any API change in the WSRP module. I present the following script to that effect:
# extract most recent version of WSRP module: only check the first 5 lines of maven-metadata-local.xml and extract value from <version> tag export CURRENT_WSRP=`sed -n -e '5 s/.*<version>\(.*\)<\/version>.*/\1/p' $HOME/.m2/repository/org/gatein/wsrp/wsrp-common/maven-metadata-local.xml` echo Current WSRP version: \'$CURRENT_WSRP\' # extract which WSRP libs are currently needed by GateIn and replace them with a fresh version from local repository for lib in `ls $GATEIN_EAR_HOME/lib/wsrp* | sed -n 's/.*\/\(.*\)-'$CURRENT_WSRP'.jar/\1/p'` do echo Copying $lib-$CURRENT_WSRP.jar to $GATEIN_EAR_HOME/lib/ cp $HOME/.m2/repository/org/gatein/wsrp/$lib/$CURRENT_WSRP/$lib-$CURRENT_WSRP.jar $GATEIN_EAR_HOME/lib/ done # deal with producer and admin GUI WARs separately as they are put elsewhere and without version name for war in `ls $GATEIN_EAR_HOME/wsrp* | sed -n 's/.*\/\(.*\).war/\1/p'` do echo Copying $war-$CURRENT_WSRP.war to $GATEIN_EAR_HOME/$war.war cp $HOME/.m2/repository/org/gatein/wsrp/$war/$CURRENT_WSRP/$war-$CURRENT_WSRP.war $GATEIN_EAR_HOME/$war.war done
Note that this script expects that you have a $GATEIN_EAR_HOME variable set, pointing to location of your GateIn EAR. Easy enough (though I had to freshen up my sed-fu ^_^).
# extract most recent version of WSRP module from existing files CURRENT_WSRP=`ls $GATEIN_EAR_HOME/lib/wsrp* | sed -n '1 s/.*\/.*-\([0-9]\.[0-9].[0-9]-.*-.*\).jar/\1/p'`
Might be faster that way…
GateIn 3.0 CR1 released!
Feb 18th
Where have I been? Well, mostly working towards releasing GateIn (we just released CR1, by the way, go grab it, put it through the motions and let us know if you find any issues).
We had a nice face to face meeting in Charmey, Switzerland with some of the eXo guys. It was nice to see my co-workers and meet new ones. Lots of good discussions. We even found a way to fit in some fun, which is always good to bind teams. Oh, and we did, of course, get to eat various melted cheese dishes and you can’t really go wrong with that!
GateIn 3.0.0 Beta 2 released!
Oct 21st
As some of you may know, JBoss and eXo have decided to merge their portal efforts in an attempt to create the best open-source portal framework out there. This new, best-of-breed portal project is called GateIn.
Integrating both code bases has taken (and still does) a lot of effort from both teams. This has translated in some long hours and little sleep but we’ve just released a new beta version for you to try and enjoy! Apart from lots of improvements and fixes, the big news is, of course, that we now provide the complete source code! Read more about it on the official GateIn blog.
Of course, we’re not done yet so keep watching the blog. You can also follow GateIn on Twitter.
Beware of File.createTempFile
Sep 4th
By default, File.createTempFile (in Java, of course) creates a temporary file in the directory identified by the system property java.io.tmpdir. The problem is that on OS X, that directory can be quite weird. For example, on my system, it currently is:
scala> System.getProperties().getProperty("java.io.tmpdir")
res0: java.lang.String = /var/folders/ya/yaNATrKPGFu2HuSOWxSIu++++TI/-Tmp-/
Notice the ++++ in one of the directory names? Well, these little characters can later cause headaches! The reason, you ask? Simple, if that temporary file name is ever used in a URL, then those plus signs will be interpreted as spaces and whatever code is using a URL to find your temporary file will not find it! So beware!
Possible solutions include passing -Djava.io.tmpdir="whatever" when you launch your Java process, or use the createTempFile(String prefix, String suffix, File directory) version of File.createTempFile and pass it a directory that doesn’t contain an + sign in its name!
Code reminder: using an isolated local Maven repository
Aug 11th
I can never remember the command line option to use an isolated local Maven repository for a given Maven run (so that, for example, you can make sure that your dependencies are properly defined and you don’t run into conflicts due to a shared repository) and couldn’t find it again quickly enough via Google so I thought I’d post it here, as a reminder:
mvn -Dmaven.repo.local=/foo/bar
First Adium / Twitter integration thoughts in 1.4 beta 1
May 19th
It’s quite funny to see that, as I finally got some time to finish my first post on Twitter OS X desktop clients yesterday, a new one appeared the same day in the shape of Twitter support in Adium 1.4 beta 1. Well, to be fair, there already was support for Twitter in Adium but it wasn’t as widely available as a public beta. Here are some thoughts about Adium as a Twitter desktop client for OS X that I gathered as I used Adium exclusively for Twitter access yesterday.
First impression
First, there are some details on how this would work on Adium’s blog. Great read on the overall philosophy of the Twitter integration.
Not surprisingly, Adium tries to fit Twitter support into a chat metaphor. People you follow are automatically added to a new Twitter contact group, which is thanksfully collapsed by default! A new section called “Bookmarks” is also added (I’m actually not sure if that existed in previous versions of Adium and I just missed it) which contains a “Timeline (name of account)” bookmark for each Twitter account you set up. This actually didn’t work the first time I tried, which was quite disconcerting. According to Adium’s developpers, this is a bug that will be addressed with an upcoming second beta. At this point, restarting Adium should do the trick.
Timelines are actually group chats in which people you follow are participants of sorts. This is the core of Adium’s support for Twitter. Any time someone you follow posts a public tweet, it appears in the group chat window (modulo refresh period, of course). Noteworthy is the fact Adium lets you select a different appearance for group chat vs. regular, one-to-one chat, which is quite useful. An example of such a styled timeline can be seen below.

Direct messages are implemented as one-to-one chats as would be expected.
Limitations
The model of Twitter as group chat has limits though. First, there is no way, that I could find at least, to have persistent search results, i.e. an updated list of all the mentions of given terms. Just like timelines for your Twitter accounts are implemented as bookmarks in your contact list, I can envision persistent searches being implemented as a different kind of timeline.
Another issue is the fact that it’s not as easy to follow conversations as it is with dedicated clients. I assume the appearance extra that you use could help but, just as Adium adds links to the right of each post to operate on them (re-tweet, reply, favorite, permalink or, in the case of one of your posts, delete), a link to open a conversation in a separate window (similar to what Tweetie for Mac does) would be helpful. Obviously, it could become confusing with direct message conversations, since that’s how they are implemented as well…
The biggest issue at this point, though, is the fact that you only get tweets that were published while you are connected. It seems, because I just discovered this as I was writing and haven’t had time to explore more, that historical tweets that occurred while you were not connected are accessible from the so-called chat transcripts where it’s difficult to quickly see which tweets you’ve read and which you haven’t. Similarly, your timeline is reset each time you restart Adium, making it difficult to follow things as some tweets will be in your current timeline while others are hidden in logs…
Conclusion, for now at least?
Adium’s implementation of Twitter support is based around the group chat metaphor. It has potential but also some serious drawbacks at this time, ones that will make me go back to a dedicated Twitter client, at least for now. Of course, the software is still in beta and might still evolve, though I don’t know that it’s not already feature-frozen. A pretty cool feature, though one not directly related to Twitter support, is support for laconi.ca servers, as well as IRC support. What this means is that I could potentially use Adium for most of my communication needs (IM, Twitter and IRC) and that’s a big plus for me. IRC support is good enough that I can use Adium instead of Colloquy for my very simple IRC needs. All that’s missing to make Adium my one-stop communication hub is better Twitter support and Skype support (there’s an Adium extra to support Skype but I haven’t managed to make it work)… I suspect this is a big upside for lots of people and a big advantage over other desktop clients. I will therefore follow with interest how Twitter support in Adium evolves and might report back from time to time…
OS X desktop Twitter clients: Twitterrific and beyond!
May 18th
I’ve had a Twitter account at the beginning of 2007 but it took me a while to really start using it. For one thing, I admit that I failed to see its potential then. Of course, it didn’t help that I didn’t know anyone with a Twitter account, thus not helping building interest… Any social application has to reach a critical mass, via positive feedback, where each new subscriber makes the whole network more valuable. I eventually got around to use it more intensively, as I started discovering usefulness to it and building a network. I do think though that the biggest impetus for me to use Twitter more was installing Twitteriffic on my computer.
You cannot underestimate the importance of a good interface to a service. When I started using Twitter, the only interface I knew of was the web version, which was failing quite a bit (state represented by the now infamous fail whale). Installing and subsequently using Twitterrific really helped me get into Twitter. I present here a short review of Twitterrific, what I like about it and what I look for in a Twitter desktop client.
Main window
Twitterrific is an application which only interface element is, when inactive, a menu bar icon (
), which allows to toggle visibility of the main application window and changes color when unread tweets are available. The application doesn’t even have a dock icon, which means that it won’t show up when you -tab between applications or doesn’t have a menu. Most, if not all, operations can be accessed via a keyboard shortcut. Of course, you can also interact with it via the mouse when the main window is shown, though as it doesn’t have menu bar, it takes some getting use to. A very useful feature is that it can react to a system-wide shortcut to display or hide the main window, which makes it easy to ready a new tweet or post something quickly.
The main window itself has a pretty simple layout though it can be a little alien at first as it is quite different from traditional OS X application windows. The timeline of received and sent tweets occupies most of the space. A simple control bar rests at the bottom, allowing you to access your Twitter home page, change Twitterrific settings (implemented as a modal sheet), refresh posts and post a new status. As you can see, it’s mostly targeted at reading as opposed to posting.
Posts are presented in reverse chronological order (most recent at the top), each displayed with its author’s avatar. Twitterrific remembers the last post you read and dim the ones you’ve seen already. Mentions are tinted so that you can distinguish them from regular posts. Same goes for direct messages. Note that there is no distinction made between replies and mentions, meaning that posts are tinted the same way regardless of whether they are direct replies or re-tweets. As long as your user name appears in it, a tweet will be tinted.
Interacting with a post
Selecting a tweet brings up three new icons, allowing further interaction. The first one is the gear menu, which provides lots of options, as shown on the screenshot to the left. A little surprising is the fact that this looks like a contextual menu, yet provides actions that are actually affecting the whole application. The second icon provides a quick way to reply to the selected tweet, while the third one sends you directly to the author’s web site, as defined in their profile.
Neat features
Twitterrific offers Growl support, the notification framework of choice on OS X. This goes very well with the overall application philosophy of staying out of your way, hidden until needed. You receive notifications when new tweets are available but you get informed in an non-intrusive way, allowing you to see them from the corner of your eye, while you keep doing whatever else you’re doing. To me, this was also a big plus to adopt Twitter, as it put me in control, kept in touch with the flux of things without having to check the details until I was ready to.
Last but not least, I find Twitterrific quite appealing to the eyes, despite the non-standard interface and it’s also very frugal resource-wise (both in terms of CPU time and RAM usage), which can be quite important when you have a bunch of applications running at the same time, all competing for your computer’s attention!
Limitations
To me, Twitterrific is terrific application for a Twitter beginner, and without which I probably wouldn’t have taken to Twitter as much as I have (or it might have taken me more time to do so). It’s also very well suited to what I would say is the majority of Twitter users (though it’s a wild guess on my part), i.e. people who mostly follow a limited number (think dozens, not hundreds) of people and post infrequently from a single account.
However, as I became more and more comfortable with Twitter, I found that Twitterrific, at least in its free instantiation, was missing some features that I grew quite fond of using my Twitter client of choice on the iPhone, Tweetie. I actually consider Tweetie for iPhone as the best client out there, all platforms considered, but that’s a story for some other time…
For one thing, Twitterrific (in its ad-supported version) doesn’t support multiple accounts, nor does it offer persistent search capability or ability to follow trends, all of which I became more and more dependent on to more efficiently use Twitter. I now commonly use 3 different accounts for different purposes and being able to use a single interface without jumping through hoops to post and read tweets from several accounts is a big plus.
Similarly, I rely on persistent search results to follow mentions of things that I am interested in (most often JBoss Portal), while I use trends an easy, real-time news engine (though one that’s obviously biased towards a wealthy, industrialized and rather frivolous society that can afford almost constant connectivity, but here also, this is a subject for a different time)… I also like/miss on the desktop the nearby functionality offered by most iPhone clients, which allow to filter tweets based on your location, which is an interesting way to see what’s going on locally and potentially find interesting new people to follow.
Moving forward
In essence, I have been searching for an OS X Twitter client that would replicate the functionnality offered by Tweetie on the iPhone. I don’t consider myself a Twitter power user but my usage pattern has moved beyond what Twitterrific comfortably handles. This is not a dig on Twitterrific. Like I said, it’s a terrific app that I would recommend in a heartbeat. I just outgrew the use for which it is optimized.
Requirements
What I want essentially from a (desktop) Twitter client is:
- multi-user account support
- ability to track trends
- ability to track search results
- Growl support
- streamlined interface (though what that means exactly is open to interpretation)
- ability to track where I stopped reading tweets
- native interface with low resource usage, i.e. not Air-based which I find quite the resource hog at this point
- free and opensource if possible (though I am not opposed to buying a client that I’d like, I bought Tweetie on the iPhone after all)
With these in mind, I’ve been / will be looking at several twitter clients to see which one sticks around. Probably more to come on this…
JBoss Portal 2.7.2 is released!
Mar 13th
It’s been a couple of really busy weeks at work as we have been ironing out the last couple of issues that we wanted to solve before unleashing JBoss Portal 2.7.2 unto the world! ![]()
It’s finally done and 2.6.8 should follow suite soon. I can now re-gather my thoughts and energy towards 2.8 and beyond!
Read more about the release from our fearless leader on the official JBoss Portal blog.
Java 5 pitfall
Nov 14th
Java 5 has some nice improvements over Java 1.4 that really make writing code simpler… Then again sometimes simpler also means dangerous. Case in point, Java 5 auto-boxing. Consider the following method:
public Boolean isValid()
{
// if we don't have any data, we cannot decide so we return null,
// which is why we're using Boolean instead of boolean
if(data == null)
{
return null;
}
else
{
// data.isValid() returns a Boolean
return data.isValid();
}
}
As you can see, we are using Boolean as a return type to provide a ternary result instead of a simple true/false decision: sometimes, we just don’t have enough information to decide and we want to know that. So far so good!
Now, we’d like to use this method within a test:
...
if(isValid())
{
//do something...
}
This code compiles with Java 5 thanks to the auto-boxing mechanism. It would be an error with Java 1.4, however, the compiler in Java 5 transparently converts the Boolean return value to a boolean. Everything seems great: we have a method that provides more information and the code is as easy to read as it was with a method that simply returned a binary result. Except that now, this last piece of code can actually fail and cause a NullPointerException because the compiler converts the code to something similar to:
Boolean tmp = isValid();
if(tmp.booleanValue())
{
// do something...
}
thus causing the NullPointerException if tmp is null… Tricky!
Now, this is nothing new (though I only realized it when I was about done with this post), it’s been pointed out several times already… However, I stumbled on it just now and though I figured out pretty quickly, it was still somewhat surprising. On the other hand, the advantage of only starting to use a Java version so late after it’s been released is that all the potential pitfalls are fairly well documented by now!
Kaneda’s bike?
Nov 13th
It was the end of the 80′s and as a dorky teenager, I was fascinated by Katsuhiro Otomo’s Akira, and in particular, its main character‘s bike. This childhood’s dream of a bike seems eerily close today with the EV-X7 prototype electric bike. Looks like I won’t have to wait until 2019 after all!
