Archive for September, 2007

Javascript Libraries

Gave a talk at the Ruby on Rails Oceania Sydney meeting last Wednesday about the various Javascript Libraries that are available for using with Rails. I covered Prototype/Scriptaculous, jQuery and YUI. I was very hesitant about making recommendations, but did try and highlight some of the reasons one may have a look around at what else is out there aside from the Prototype/Scriptaculous standard.

The talk was well received and there was some good discussion. I learnt a few things that I didn’t know before as well, and I’ve also learnt more afterwards too (such as YUI often breaks compatability with their upgrades, and their versioning is rubbish).

I’m not going to upload the slides here because I really only had “placeholder” slides that I spoke to, rather than informational slides. This post is more a note that the talk happened, lest I forget about it in the future!

Remote Debugging: Tomcat 5 + Eclipse

I can’t remember how many times I’ve had to set this up, but I always end up wasting time googling an answer, which is mostly good, but sometimes misses the mark (Jon Eaves’ remote debugging solution is closest to the mark, but his is a Windows solution.) For the record, here is how I just did it in OS X:

  1. Make sure normal Tomcat environment variables (CATALINA_HOME, JAVA_HOME etc) are set.
  2. At the command line:

    $ export JAVA_OPTS= "-Xdebug -Xrunjdwp:transport=dt_socket,address=8000,server=y,suspend=n"
    $ startup.sh
  3. Note: I didn’t have to include “jdpa start” arguments
  4. Go to Eclipse, then Run->Debug…
  5. Then create new “Remote Java Application”, rename it and run (the defaults should be fine)

For the record, it’d probably be better to run Tomcat directly from Eclipse, but I don’t have time to set that up right now — so tried and tested it is.