Archive for October 2007

Live blogging

I’m currently at the OpenLearn conference and have helping with the live blogging effort on the Ochre website. However I’m finding this a little tricky – I’d be fine taking notes then writing up later, but my brain doesn’t work quickly enough to form sentences worth posting up as people are presenting. Think the best bet for me is to listen to the presentations then write up my overall thoughts at the end.

Think I may be making thing even harder for myself by writing to this blog and the Ochre blog at the same time…!

IE crashing with MSG

Came back from holiday yesterday (see the pics!) , to find a stack of emails about problems with MSG crashing IE. This is a bit odd as we’ve not updated MSG for a little while, so strange that it just seems to have started occuring. It seems quite an erratic problem, but it does bring the whole browser down – something I find a little odd for a purely javascript application.

I’m really hoping to get this fixed very soon, but haven’t yet found the root cause, I can reliable recreate the issue, so just need to find why it’s happening.

Plus I need to get my presentation for next weeks OpenLearn conference written sometime soon!

Update (29th Oct)… I have now got the problem resolved, though still don’t know the real root cause. I fixed it by going back through the changes I’ve made recently and seeing at what point the error started occuring.
The change which appears to have been causing the error was when I switched from using <a href=”javascript:….”> to using (what I thought was the proper way!) of adding/removing event listeners. The actual problem occured with the call to detach event, although it didn’t fail everytime – it would work for the first few times and then randomly cause the browser to crash. I did notice that the carsh would only happen if I had the MSG client and the referring site (the one with the users presence icon) open at the same time, if only one was open the crash wouldn’t occur.

For info this was the code that was causing problems:

var oldImg = presenceNode.firstChild;
//remove any current listeners
if(oldImg.removeEventListener){ // Mozilla, Netscape, Firefox
oldImg.removeEventListener('click', launchClick, false);
oldImg.removeEventListener('click', readMessageClick, false);
} else { // IE
oldImg.detachEvent('onclick', launchClick);
oldImg.detachEvent('onclick', readMessageClick);

So I replaced this with the code below that just alters the location and title of the link (also a bit of adjusting to add the <a> in):

var oldAnchor = presenceNode.firstChild;
var newAnchor = oldAnchor.cloneNode(true);
newAnchor.href = "javascript:readMessageClick();";
newAnchor.title = MSGAPIconf.str_oneMessageUnread;

So, glad to have got it fixed, but would be even better to know why this was really happening at all!

Update Number 2 (1st Nov) – The fix has now been made live on the MSG-OpenLearn servers.

OpenId servers – any good ones out there?

Over the last few days I’ve been taking a look at OpenId and how we could use it to solve some of the single sign on problems that we have – and in the process making some of the KMi tools OpenId-enabled.

We would like to set up our own OpenId server, mainly out of interest, but also so not then relying on an external service to be our OpenId provider. Whilst there seems to be a fair amount of documentation and usable code out there related to making your site (esp blog) able to be an OpenId consumer, there seems to be very little about the OpenId server.

There are a few OpenID server libraries available and standalone servers, but generally they appear to be very poorly documented. I was just looking at libraries/servers for PHP or Java (our ‘normal’ development platforms), but some lacked clear instructions on how to set them up, or the examples didn’t work. Out of the 5 or 6 that I tried, I was unable to get any of them working – ok, I’ve not spent a huge amount of time looking at these, but with most I was pretty stumped as to where to even start getting them running.

I know some people might say that many of these are open source projects, so if you don’t like it then do something about it (write some docs, get the examples working etc), but I just don’t have the time at the moment to try and figure them out in that much detail. Maybe the people who have got them running could write some clear(er) documentation?

I think it’s in the interests of the OpenId Foundation to make help these OpenId server projects improve dramatically if OpenId is going really make a difference to the single sign on problem. My feeling is that most organisations would not want their logins handled/maintained by some outside service, so they’d want to be their own OpenId provider. So if stable & easy to setup/use/integrate OpenId servers aren’t available, then this will limit the take up of OpenId by organisations who have the same issues we do in KMi, with tools/services needing different logins.

I’ve emptied my Netvibes page

Just been having a tidy up of my RSS feeds – I had some in Google Reader and some in Netvibes and some bookmarked in FireFox, which all seemed a bit daft, so I’ve moved them all to Google Reader. This now means that the only thing I’ve got left on my Netvibes page is the GMail widget and my MSG widget – which now makes my Netvibes page redundant, I’m usually logged in to MSG via MSGAlert seperately anyway, so that basically leaves GMail – and if that’s all that’s left, I’d just go straight to GMail.

Not really sure what I think about that – maybe it’s just the way I’ve been using Netvibes and the widgets I’ve been adding…

Future of web apps

Spent the last few days at the Future of Web Apps conference, and, as with the previous one in February, loads of excellent presentations and lots of food for thought. Also managed to wrangle myself a place in the workshop sessions, which were well worth it. Here were the highlights for me…

Steve Souders (Yahoo) on high performance websites, excellent tips on how to improve the response time in your web app. This was all focussed on improving the speed of the front end, rather than the more usual approach of improving backend speed (with database optimisation etc) – but as he demonstrated, the gains are much more significant when applied to the front end. Steve also gave a workshop on the same subject – his presentation slides give all the info you need – rather than me repeating it all here. Steve’s team have built a plugin for FireBug, YSlow, making it easy to show how your web app scores against his 14 rules (see the presentation for details of these rules). The only one of these rules I would question, for all but the biggest of web sites/apps, is the Content Delivery Network (CDN). Out of interest, I ran YSlow against our OpenLearn site and there is definitely some scope for improvement.

Dion Almaer (Google) on Google Gears, this was broadly the same as I’d heard at the Google Developer Day and I’m still not totally convinced it will get huge take-up. The reason being that I think it’s only really relevant for a small slice of web apps – eg for salesmen-out-on-the-road apps – or maybe I’m being unfair, being able to use GoogleDocs when not online would be good. I am quite interested in the WorkerPool with thread-like JavaScript, and would be fantastic if this could be implemented in JavaScript generally. I should probably mention that I do actually like the fact I’m not always connected to the web!

Robin Christopherson (AbilityNet) – I think this is the first time I’ve been to a mainstream web development conference where there’s been a presentation highlighting how to develop for visually impaired users and I’m sure (hoping!) his demo of screen reader software (especially the reading of the image names on the Amazon tabs) was an eye-opener (excuse the pun).

Heidi Pollock (BluePulse) on the mobile web and all the associated complications and headaches due to the sheer number of different web browsers used on different phones and the screen size you can actually work with. Before her presentation I would have had no idea where to start designing an app for mobile phone, now I do, but whether I want to cope with all those headaches is another matter!

John Resig (JQuery) gave an insight on the future of JavaScript (v2). Though I have a voice in the back of my head telling me that it’s just converging with Java, for example, optionally giving variables types and being able to import packages of classes. However, ignoring my fears that this is reinventing Java, it will certainly be good to see some more ‘real-programming’ type principles applied to JavaScript. I did learn Java before JavaScript, so maybe I’m biased anyway. Another thing John mentioned and is applicable to the work I was looking at alerting user to a new MSG message with a beep, is the implementation of <video/> and <audio/> tags in HTML 5.

Joe Walker (DWR) on Comet and attempting to get over the hurdle of the fact that the web is a pull technology. This is something we had to address with MSG, being able to push new message notifications and presence state changes out to the user. We achieved this by use long running connections, only returning if some needs pushing out to the client, or after around 45 seconds. So I’ll need to look into whether comet can give us a better/different approach.

Tom Coates (Yahoo) showing FireEagle (though it’ll have a different name on release), a way of sharing your location, so relevant to me with the MSG – Google Maps integration. Essentially it provides a service that applications and devices can use to either write or read your current location. So you could have your mobile phone automatically update where you are now (using GPS) and have this fed out to Twitter. This could be a really good one for us to look at for MSG and auto updating your location rather than relying on someone remembering to go update their location. As Tom pointed out, there are loads of potential privacy issues/concerns (“Burglary 2.0” was mentioned during the Q&A), but they seem to have done a really good job of addressing and anticipating these.

And last, but by no means least, Michael Kowolski’s (Kitsite) workshop on Interface Design for Web Apps, reminding us just how critical a good user interface is – and he wasn’t just talking about the graphical design. Everything he mentioned ought to be common-sense, obvious and in-built to web app developers/designers, but to me it highlighted just how often and easily it gets overlooked. Creating a easy-to-use and intuitive interface actually requires quite a lot of thought and planning, the fact that the user doesn’t have to learn the interface is a *good thing*.
It did make me think that Moodle has a way to go in this respect, I know that Moodle has ‘themes’, but essentially this is just changing the CSS and a few graphics, and that’s not really changing the interface. Michael is going to post the presentation up soon (here), and it’ll be a good one to look through again.

All in all, a thought provoking few days, and makes me wish I had far more time to investigate in detail all I’ve found out. The final thing I’ve learned is that I ought to get into the habit of blogging live, rather than leaving it till I get home and trying to remember all the excellent stuff I found out about! (or take better notes…)