February 21, 2009

tweetbox.org

My TweetBox project hasn't seen much of my attention in these last few weeks. I have only done a few minor tweaks here and there. I am still struggling with performance issues. I have tried to speeds things up by moving some JavaFX code that was juggling blocks of memory to Java. I also replaced all my Vectors with HashSets to make looking up and sorting objects faster. According to the Netbeans Profiler, those measures have defintely improved things (it made some hotspots disappear), but the user experience is still the same: sluggishness.

I have also spread the retrieval of tweets from the Twitter API during start-up such that it no longer loads several streams in parallel, but one stream at a time. That did have a noticable effect. The application has become more responsive because of that.

You can see for yourself in the development version.

O, by the way, I have bought a domain name for my project: tweetbox.org. It is so cheap to do that these days.

February 10, 2009

Cruise controlling Adobe Flex/AIR development using Tamarin

In the last few years I have been involved in several software development projects. Some projects in pure Java, Some projects in Pure Adobe Flex, and a few mixtures of these flavors.

I am also a big proponent of continuous integration. An awesome tool for that is Cruise Control. I have used Cruise Control in one of the above projects, and that made life in that project so much easier. It takes some effort (a few days) to setup and fine tune Cruise Control, but once you have done that, you gain the following enormous advantages:

  • immediate feedback on broken builds,
  • always up-to-date API documentation,
  • immediate feedback on code quality.
Cruise Control basically works like this: It monitors the state of your project's source code repository (CVS, Subversion, ...). If anything changes in that repository, it gets an update from the repository, and rebuilds your project. Depending on what you specify in your build script, this could be anything a developer could do from his work station. Usually, the following artifacts are produced by a full project build:
  • Deployable/installable binaries of the target system's components,
  • Unit test reports,
  • Code metrics reports,
  • API documentation.
In the Java/C++/C#/.Net communities, doing continuous integration is already pretty much a default project practice. Been there, done that and bought the T-shirt! Now I come to think of it: setting up continuous integration probably moves you well into level 3 on the CMMI scale (but don't quote me on this, because I haven't verified that).

In the Flash/Flex/AIR community, continuous integration is probably very rarely used. I have often thought about setting up Cruise Control for a Flex development project, but I always got stuck at the following inabilities:
  • can't produce unit test reports,
  • can't produce code metric reports.
For automatically running your unit test cases, you need to be able to run actionscript bytecode in "console mode" (i.e., no GUI). The unit tests would produce success/failure reports in a format (usually XML) that Cruise Control later combines into a single XML stream and transform it to a neat human readable HTML report by running it through an XSLT script. In spite of the grandness of the Flex SDK and Flex Builder, the Flash Player doesn't have a console mode.

And as far as I can see, there is no decent (or even half-way decent) code metrics and quality analyzer (such as PMD and Checkstyle for Java) for Actionscript. And again, these analysers should be able to run in "console mode" and produce a report that can be processed by Cruise Control.

But, today, I have seen the light! And it comes from the Tamarin project. Tamarin is an open source ECMAScript Virtual Machine, contributed by Adobe to the Mozilla fondation. I found this rather dated but still very useful blogpost by Zwetan Kjukov explaining how to build the Tamarin VM. Following the instructions on that blog, you would obtain an executable binary named avmplus, which you can use to run Actionscript bytcode in console mode!

Now, I haven't tried to reproduce the steps in Zwetan Kjukov's article, but I intend to whenever I find the time and oportunity to do that. And the results from that will be nice material again for a blog post.

On the Tamarin pages, I also found these instructions on how to build the latest stable release of Tamarin.

Has any of you already experimented with continuous integration in Flex/AIR projects? Please share your experiences!

February 09, 2009

Broadcast yourself with MyBlogLog

I am trying out this new Yahoo service called "MyBlogLog". The service allows you to setup yet another online profile. A powerful aspect of MyBlogLog is that it lets you associate your profile with just about any other online profile you might have. The list of services MyBlogLog currently recognizes for this is impressive.

Once you have setup the bare basics of your profile, you can already create a customized widget and e-mail signature that you can use to promote yourself and encourage readers to follow you on twitter, become friends with you on Facebook, follow your diggs, ... .

My e-mail signature currently look like this. Nice eh?

Mark Nankman
UX Architect and Social Media evangelist


However, I am not too sure about this service. It looks nice, but why would I want to use it on top of all the other services I am already using. That's the whole problem with social media, isn't it? There is too much to choose from. Perhaps, "social umbrella services" such as MyBlogLog can solve that problem, but for now, I am not yet convinced.