Posts Tagged ‘web apps’

Google Wave and IE-Support

Friday, September 25th, 2009

So after all Google has developed its Chrome Frame plugin for Internet Explorer for a good reason: enabling the majority of users – which are unfortunately still using Internet Explorer (6,7 AND 8) to have a better experience with HTML5-based websites.

Lars Rasmussen posted on the Google Wave Developer Blog that Wave will inform Internet Explorer users to install Chrome Frame for a better user experience. Reason being that Internet Explorer is just too slow at interpreting JavaScript and DOM Manipulations – features Wave heavily relies on. IE’s support of modern web standards such as HTML5 is pretty poor, too.

I’ve been experiencing the same issues with IE over and over for myself – yet in a smaller dimension: Every hour (and it have been many hours) a developer spends on the specific quirks on IE (which of course are different per each version) and to fix them for their application is not spent on adding cool new features or bug fixes which affect general issues.

Since this has been a problem for so a long time I hope this finally helps to fix this issue.

A few updates on GInstruments

Wednesday, May 27th, 2009

After some days off last week I’m on it again… GInstruments definitely on the way I’d like it to be.

First things first: Fortunately Hyperic had placed an exception-statement into its GPL-licensed SIGAR – which allows to include the SIGAR binaries in – for example – Apache-licensed works. For me that’s really good news, because this means GInstruments could also be used in productive environments which I think often would not be GPL-compliant.

Second: One of the basic things I always wanted to have seems really close now. At the moment GInstruments only displays your current system usage – not too useful, because most times you’d be interested in the usage over time, say for the past 30 seconds or so. So that’s one of the core features I’ll be implementing before releasing anything to the public – sorry for the delay, I’m very busy in other projects right now, too.

For the next few weeks I’ll also be testing on various kinds of systems (Windows, Linux, …) and of course testing on Google AppEngine whether they support all the necessary features.

And for a great user experience I’ll also be working very hard on a prototype of the UI.

Some things that will probably make it into the first public release include:

  • logging system usage and events to a set of CSV-files (configurable in later versions)
  • usage graphs on the client-side using flot
  • more? yeah, sure!

GInstruments – a new Grails plugin… soon!

Saturday, May 23rd, 2009

As a developer I’m very often on the hunt for every last bit of performance – trying to optimize every single function of my program.

In the past weeks I’ve been thinking of, designing and developing on a new plugin for the growing framework Grails. It will be called GInstruments and it aims to provide some useful clues for Grails developers who want to know how their application is performing.

The plugin uses Hyperic’s (now SpringSource) SIGAR (System Information Gatherer And Reporter) to report vital system information such as CPU usage or memory comsumption overall or for the current process.

The first release (0.1) is only going to be a snapshot of my first ideas, hence I’ll not release it to the official Grails plugin repositories. It will show you some information about your system like name, version, vendor or architecture, the current CPU and memory consumption. Especially for your current process (which will be the relevant information to know). Take a look at this:

First draf of GInstruments 0.1

First draft of GInstruments 0.1

All these features are subject to change (I first wanted to know whether there could be a future for this). Possible features for the future may include

  • logging of metrics (cpu, memory, swap, network, …)
  • tracking of Grails events (requests, …)
  • visualization of these two and more components over time to detect points of interest

I’m open to all kinds feature requests but please bear in mind that I’m only doing this in my spare time, after work, school whatsoever ;-)

At last let me point you to a link (for the non-Apple-developers) to how Apple’s Instruments-app looks like. I think it has some other cool possibilities.

At the moment I’m also waiting for some response from the guys from Hyperic. I really want to license the plugin under the terms of the Apache License (the license Grails uses and many other plugins) – SIGAR is GPL-only at the moment.

Do you think this could be a useful plugin for the Grails infrastructure? What’s your opinion.

Grails – ImageTools-Plugin

Friday, May 8th, 2009

There have already been some posts about the Grails Framework on my blog, so here’s one about the ImageTools plugin. This plugin leverages some functionality of the Java Advanced Imaging API (JAI) to make handling images a lot easier for Grails developers. However, some people seem to be complaining about poor image quality – I guess they’re about the poor resizing-results when using the thumbnail functionality.

The default method for creating thumbnails is the following

def imageTool = new ImageTool()
imageTool.load("/path/to/image.jpg")
imageTool.thumbnail(640)

This will load the file, create a new ImageTool instance and make a thumbnail out of it, where the max width/height will be 640px. However the resizing quality is very bad because by default it uses nearest neighbor for interpolation. You will encounter this especially when you’re rendering small thumbnails out of large images.

A possible solution

Because there is no detailed documentation about the ImageTools plugin (actually I didn’t find any) one will have to inspect the source code to find something very cool: ImageTools also provides a method called “thumbnailSpecial” which can use other interpolation and rendering algorithms and you can use it instead of the basic “thumbail()”. It’s signature is as follows

thumbnailSpecial(float maxWidth,
                 float maxHeight,
                 int interPolationType,
                 int renderingType)

maxWidth and maxWidth are pretty self-explaining, just set them to the same values (for example 640) to achieve the same dimensions as above.

interPolationType is one of

1: “bilinear interpolation” – which is at least better than nearest
2: “bicubic interpolation” – which is even better and
3: “bicubic2 interpolation” – which may even better

these are JAI names for them, don’t ask me about the details

renderingType is one of
1: “scale” – the default function JAI uses
2: “SubsampleAverage” – which will provide better results

Please keep in mind that all the “better results” require a lot more rendering time and are likely to consume more memory – but the results will be way smoother then.

So that may help some people out there which have experienced poor quality at this end.

For me there are only two further caveats when using ImageTools/JAI.

First: performance is very bad when using pure Java mode (which will be the default unless you provide a “native accelerator” for JAI). On my Mac this is no problem – as far as I know Apple provides a native accelerator in its own JDK on Mac OS X (and I never got messages like detailed on the plugin page) – yeah, using CoreGraphics/CoreImage, whatever… correct me if I’m wrong ;-) but I never got it to run on my production system (Ubuntu Server).

Second: JAI seems to have some other strange problems with JPEGs on Linux (I tried both OpenJDK and Sun’s JDK, always JAI in pure Java mode): some JPEGs will have inverted colors in the resulting thumbnail – couldn’t find out any details but I think something about the JPEG implementation is broken. This also affects saving JPEGs for me. It got strange exceptions when saving images as JPEGs causing that to fail – so I fell back to using PNGs – which is everything but cool in many cases :-(

As said these two problems only occurred on Linux (Ubuntu 9.04) – not on Mac OS X (couldn’t test on Windows) – but since most web apps I’m writing will be running on Linux some day this is a very annoying problem – and unfortunately I don’t see any progress on the ImageTools plugin or JAI. Anybody else got this kind of problem?

So I’m very tended to give something like good old ImageMagick a try – maybe using im4java or JMagick – or something else.

Web-Apps über Web-Apps?!?

Monday, July 7th, 2008

Es scheint kontrovers: Lange Zeit stand ich Web-Anwendungen und Frameworks wie ExtJS oder qooxdoo und deren Entwicklung erleichtern kritisch gegenüber. Sie waren einfach nicht das Gleiche wie die mir vertrauten Anwendungen auf meinem Desktop.

Irgendwie “fühlten” sie sich einfach in der Bedienung nicht so komfortabel an. Ich fühlte mich nicht “in” der Anwendung sondern “davor”. Die GUI-Widgets reagierten noch ein wenig träge, es waren die kleinen Dinge in der Nutzung, wie z.B. dass ein SplitPane bei qooxdoo beim Resizen nicht live neugezeichnet wird sondern erst mit Abschluss des Events. All das sorgte bei mir immer für ein Gefühl des Neben-sich-Stehens bei der Bedienung solcher Web-Apps.

Auch ließen viele Frameworks (oder die Entwickler der darauf aufsetzenden Anwendung) oft Navigationshilfen wie sinnvoll platzierte Tabstops oder Features wie ein “Return heißt OK/Submit” vermissen – für mich als Tastatur- und Shortcut-verliebten User durchaus ein Hindernis.

Doch mittlerweile unterläuft mir bei den immer mehr genutzten Web-Apps dagegen ein Fehler, der eher vom Gegenteil zu zeugen scheint. Man stelle sich folgende Situation vor: Ich schreibe gerade eine Mail über GoogleMail und möchte kurz eine Website aufrufen. Instinktiv nutze ich (am Mac) die Apfel-Tab-Kombi um zu meinem Browser-Fenster zurückzukommen – nur um festzustellen, dass ich mich schon im Browser befunden hatte.

Wenn ich mir nun noch das neue MobileMe in den Demos von Apple anschaue, mit einem Look&Feel der im ersten Moment klar an die gewohnten Desktop-Apps erinnert so wird mir Angst und Bange (nun ja, so schlimm ist es auch wieder nicht) dass mir dies in Zukunft durchaus noch viel häufiger unterlaufen könnte – auch wenn ich MobileMe in nächster Zeit nicht nutzen werde. Es werden sicher genug andere Anbieter nachziehen.

Sieht man z.B. diesen “Finder” für die iDisk:

iDisk - Apple MobileMe

auf den ersten Blick sieht das Ganze doch mindestens so komfortabel aus wie der echte Finder. Wenn man nun noch annimmt – und das kann man bei Apple wohl getrost tun – dass sich in diesem ähnlich flink mit der Tastatur navigieren lässt… wohl schon sehr bald wird der Unterschied zwischen Desktop und Web Anwendungen völlig verschwimmen, auch da es mittlerweile Frameworks wie Google Gears gibt.