Thursday, January 04, 2007

A New Web Annoyance

I've come across two sites today (oddly, both were blogs hosted on blogger) , that have a somewhat annoying popup over links, that gives you a preview of what the link looks like. Of course, there's no direct way of turning this off (fortunately, Adblock comes to the rescue - adding* as a filter gets rid of it).

If I wanted such functionality, I'd already be using Cooliris (which I have installed and do use when I want that functionality - mostly on ebay). I really don't need or want sites adding such functionality for me (especially if I'm running Cooliris)

It really reminds me of the midi files and flash tags of the mid-90s. It looks kinda cool the whoever wrote the site, but kinda sucks to anyone reading the site.

Tuesday, November 21, 2006

NoMachine - The Coolest Thing Since VMware

I finally got around to giving NoMachine a go, and it works great! At the weekend I got around to getting the machine that I was planning on using with NoMachine (and eventually, Xrdp) up and running (I can't remember if I've had that machine sitting around for 1 year, or for 2). I can sit at work and (thanks to some ssh tunnelling) "forget" that the machine I'm actually using is back at the flat. It gives the same sense of "coolness" that VMware gives.

One of the things I've found really useful is session suspend - so that I could connect to the NoMachine server from inside the flat, then suspend the session, go to work and then resume the session, picking up right where I left off.

One thing to note, when using ssh to tunnel the ssh connection that NoMachine will be using (ie, ssh into machine A with a -Llocalport:B:remoteport, so that I can ssh into machine B via machine A) be sure to set "enable SSL encryption of all traffic", otherwise it will try to use ports that aren't being tunnelled and will fall over.

Another thing to note, the "new" machine is running Xubuntu, as it's not a particularly high spec machine (256Mb of RAM and Dual 600MHz P3s), so I use "dbus-launch --exit-with-session xfce4-session" as the custom command to run.

Tuesday, September 05, 2006

EntityManager Injecting Again

I better write this down, as I'll be needing it again when the app I'm writing gets deployed - from this page, the way to get the EntityManager injected again is to add the following


to the APP_SERVER_HOME/domains/domain1/config.default-web.xml (I put it down at the bottom, just before </webapp>)

Tuesday, August 29, 2006

Model Driven Development

IBM's System Journal is running an issue on Model Driven Development. There's something that bugs me a bit in the introduction -

Amazing feats can now be accomplished with sophisticated modeling tools. For example, the latest Dassault Aviation commercial jet, the Falcon 7X®, was designed, simulated, and had its entire bill of materials generated by a CAD/CAM system. It was the first airplane ever designed that flew without any physical models ever being built and discarded. Millions of dollars and significant amounts of time were thus saved. In addition, the completeness of the model makes testing the comfort and safety characteristics of the airplane very simple and quick.

In light of this, the question should be why not model complex software applications

When will people realize that developing software isn't anything at all like building a jet, or a building or any other analogy often used when people are promoting their "improvements" to the software development process? If you must come up with a real world analogy for software development, one good analogy would, oddly enough, be model building.

That's what bugs me about this introduction to MDD - pretty much all software development is in essence the development of a model. So it's hard for me to see how you could make a model of a complex software application that isn't the application itself, unlike with jets and buildings, where the model is far removed from the final product. While MDD operates at fairly high level, from what I've seen of it, you'd be hard pressed to find a MDD tool that doesn't output some form of runnable code. This means you're not really building a model of your complex application separate from your complex application, you're building your complex application. Don't get me wrong - I think there's the potential to get a lot out of using MDD tools - what gets me is the inappropriate analogies to various forms of engineering.

Monday, June 12, 2006


I had my first use of Groovy, the Java Scripting Language (no, not JavaScript :-) ). It's basically a version of the Java language that sucks less. It feels like a mixture of Java and Ruby.

The language itself is fine - they ripped the verbosity out of Java, and it can access Java libraries - which is both a benefit and a curse as while it offers access to a large library, a lot of the Java API (like the Java language) is a bit verbose at times. Still, groovy has some syntactic sugar that lets you avoid using the Java API at times (especially with JDBC stuff, which is why I was using Groovy today).

If you know Java and Ruby/Python, you'll be right at home with Groovy.

Thursday, August 04, 2005

Connection Pooling with Tomcat

I finally got pooled connections to both MS SQL and Sybase. For something that you would think would be straight forward, it's not. Some of what I encountered:


ResourceParams don't work. All the documentation I found about connection pooling says that you should define your pool as such:

<Resource name=".....">
<ResourceParams name="***same as above***">
various <parameter> tags here

This doesn't seem to work. Instead, you dump all the parameters for the resource into the resource element. OK, I haven't been using Tomcat for long, but splitting the resource's parameters away from the resource they parameterize seems a bit odd anyway, so I'm not that bothered by this. If I get some free time I should try a connection to MySQL with ResourceParams and see if that works, as what seems like 75% of the example out there use MySQL (the rest is mostly Oracle) and they all use ResouceParams.


As several apps on the same web server are going to use the Sybase connection, I wanted to use the main server.xml to hold it. I used the admin app (which of itself was another joy to get up and running, as the doc's say you need to install it separately, but don't bother to point out where you get it) to insert the resource into server.xml. However, even though the resource was placed into server.xml, it didn't work - I had to place the resource in the conf/catalina/localhost/XXXXX.xml file (replace XXXXX with the name of the app) and it did work. But as I actually do want that resource to be server wide, I'm going to have to play around with getting it to work.

"application name".xml

That XXXXX.xml file I mentioned above has a habit of getting overwritten. It gets rewritten when you redeploy the war file (which is not that surprising), but it also seems to get blanked out at other times (perhaps when the server is restarted). I'm hoping there's some way to get it to stay with the content I want. I suspect the contents of context.xml get placed in their, but I'm not sure - I had been playing with putting the resources in context.xml earlier in the day, but that didn't work - however that was when I was still trying to use ResourceParams, so I will try it again with just Resource elements.


What's really getting me is how undocumented it all seems. Even the book I have on Tomcat 5 (Professional Apache Tomcat 5) doesn't go into any great depth on the subject - in fact it seems to be little more than what's already in the Apache Docs.

Friday, February 11, 2005

Upflickr 0.1 released

I've released version 0.1 of upflickr, a command line uploading tool for flickr. It can be found here.

It's a bit rough when it comes to installing, as in it's just the source code (but as it's a python script it's runnable straight from source). And there's some other stuff I want it to get it to do, but it is at least in some form of state to show the world.