Sunday 11 November 2007

Windows Install : Bad news

hmm, it seems that my Hardrive is sort of dead. It now says "S.M.A.R.T status BAD", and exit the boot sequence, even when I try to boot on the CD... No good at all...

I tried to boot on the Windows install CD, and copy the Hard Drive to an external disk, but at first the Drive was not even recognized. I then tried to disable (temporarily) SMART in the BIOS, and it boots, but when it seems to never enter into Recovery, the CD seems to not work at all anymore..

There is a high chance that I will not even be able to backup my files to my external removable drive. Even if there are few files I have only on this hard drive, I'm sure there's some...

Plus I worked part of the Week-end to finish some very important programming work, I have almost finished, but it's on the Hard drive...

Update (23:00) : After numerous attempts, I found a fantastic utility program called UBCD. It's a Linux tool (a Windows version is available, but is not up-to-date), but it's not a problem when even your OS can't boot... So I booted on a CD created with UBCD's ISO image. Their is a collection of utilities, and some of them are able to recover hard disks failures... (like with late floppy disks). Using it, I was able to reformat the hard drive (quick reformat, I hope to be able to get back some datas after all this mayhem), and launch the XP installation program. Only time will tell if it will work at the end.

However, I will try another tool (called gdbfn) after that. This tool is seemingly able to recover datas on a hard disk, even after a quick reformat... hmm, and after all that, even if it works, I think I will need to change my laptop... I'm still on SMART option disabled, after all, this is not very good, don't you think ?

I'm doomed !!

Windows XP reinstall

Hmm, it is the second time I have to repair the Windows XP installation on my laptop (I'm blogging on my old, old old Windows ME PC).

The first time it was a problem with the file performing the boot (I don't remember its name). It suddenly appeared as a user file directly under C:\ (it was NOT considered by Windows as a system file, nor was it masked) Sure it was a problem with my Windows installation, because it should never be there, and never be visible by default.And But once I made a BIG BIG mistake, I deleted it... Of course, I could not boot anymore. The reinstalling process was not so simple, because when you phone to the Microsoft help center, which is on the XP box, they just tell you to look on Internet. Hmm, how do you do that if your PC does not want to boot (I was in my mother's appartment, and did not have access to internet) ? Typical of MS$ attitude toward customers :-(
OK I could fix that at the end (by myself, no help at all from Microsoft).

This time the PC (which is almost never connected, I'm using my older PC for that) crashed while doing nothing in particular, and crashed again repeatedly after that (hello happy blue screen, and hello again, and again, and again...). After a while, Windows changed the boot sequence itself (while not, isn't it funny ?), trying to boot on the USB device (seems to happen a lot with XP, my cousins had exactly the same problem with their PC).

You probably would tell me that at this point, a reinstallation was the only thing to do... You are right, of course. But reinstalling Windows is not always simple. First you must be aware that you have to type ENTER as new Install, and not R as Repairing, even if you only want to repair the previous installation (tell me if you understand anything).
OK, and after that Windows try to install on \WINDOWS, yes, not C:\WINDOWS, but just \WINDOWS, a directory which does not exist. So you have to change manually the installation directory...

I'm just at this point now :-(. Windows sucks a lot !!!

Saturday 27 October 2007

On .NET

OK, I personally prefer Java over .NET, maybe because I used it for some time now, so it's easier for me to understand it.

But I don't understand this hype (mainly on the net) about all these new Microsoft technologies. For example .NET is almost described as cross-platform and freely available. But think about it twice, guys:

  • Only the core part of .NET is an ECMA standard, free from Microsoft patents. Much of the "cool" parts (and much of the base class library) are patented Microsoft technologies, that can not be implemented freely. Mono implements much more than only the core part of this technology (you can do nothing with only the core), but according to the Microsoft - Novell agreement, you can use Mono freely only on Suse.

  • People say that .NET is now available on Linux as well as Windows because of Mono, but the Mono team (even if they did some great work) have not implemented all .NET 2.0 yet. .NET 3.0 is available since end of 2006, and .NET 3.5 will ship beginning of 2008. So much for the cross-platform stance...

  • Silverlight is a new runtime to build rich-internet client applications... but it is bound to a specific Microsoft technology. I don't like flash very much for the same reason...

  • And as for XAML, it does what SVG and XUL already did, but it is another specific (they even defined different keywords for the same concepts). And try to find the XAML specification in the Web, you will find it very hard, because there is none.


This list could go on an on... And in the same time, people are saying that Java is not free because 4% of the encumbered JVM code has still to be freed by Sun...

As for me, I will still stay away from all these specific technologies...

Saturday 21 July 2007

Web 2.0 considered harmful

Shocking title. It's just that we have begun at work to develop a web 2.0-ish app, mostly to experiment technologies for a particular type of application.

Well, I agree that Ajax + DHTML + Javascript can be powerful, and deliver a great user-experience, but I must also say that these technologies are not easy to implement:

  • html + Javascript does not work the same on different browsers (at all !!). We were lucky to have only to support Firefox, but supporting also IE6 + IE7 can be a nightmare. When you want to do dynamic html, never, NEVER expect behaviors to work as you expected at first (you will end with a long, long litany of if-then-else depending on the browser).

  • there is no simple ways to add simple widgets that work out of the box. Even if you want to add such basic things as scrolling, sliders, etc.. you need to use third parties Javascript libraries. There are not so many free ones out on the web, they are not so easy to implement, and when they are not working as expected, it is not so simple to debug (even with wonderful add-ons like Firebug).

  • Javascript is a limited language, and its behavior depends on the browser. For example, hastables in Javascript are extremely limited, and their behavior depends on the browser too.


I really don't understand why people always say that Web 2.0 is so much the future that it will kill fat clients. OK, you can achieve great UI results, but saying that it is simple to do is a lie, and one can not say that browsers are thin apps. The only thing that is simple, compared with languages like Java for example, is the fact that you never have to compile anything.

OK, you will say: try Apollo, or Silverlight, this is the next move in internet programming. Humm, I will try these some days, but I would say :

  • all these frameworks are still Beta, so I think it can be better for the moment to experiment, but wait a little for something more stable

  • these frameworks are relying on some proprietary technologies (Apollo relies Flash, a proprietary technology from Adobe, and Silverlight is Microsoft-proprietary

  • there is already Java (+ Web Start), and XUL, why not using what is already working for some time now ?

Monday 28 May 2007

Performance of Batik under Java 6.0

As I use it a lot, I tried to measure the possible boost of performance of Batik, the pure Java library which handle SVG files, under Java SE 6.0, compared to Java 5.0. I decide to create a small benchmark, similar to the one Dave Gilbert, the creator and maintainer of JFreeChart, did, some times ago.

To make it simple, I decided to benchmark the time spent by Batik from the parsing of the SVG file, to the rendering of the associated image on a JFrame. To measure the performance, I call the method 100 times (yes, maybe not enough times), and measure the elapsed time.

Finding good SVG images is not so simple, because time is not only linked to the size of the file, but also to what it contains (for example, complex renderings like gradients take much more time to compute).

And of course, I used Batik 1.7 Beta 1 and rebuilt it for Java 5.0, then 6.0, before doing all this.

Here are the results on my XP box:

Average performance boost is approx. 20%, this is good !!

For some more informations about the different SVG files that were used, they are all coming from the Batik samples library. You can get these samples either by downloading the snapshot here, or much simpler by getting them from the SVN viewer on the trunk here. For more informations about them:

  • asf-logo size is 100 Ko, and it uses a lot of gradients

  • batik3D size is 104 Ko

  • anne size is 86 Ko

  • strokeFont size is 70 Ko

  • moonPhases is 95 Ko, and uses a lot of gradients

  • sunRise is 67 Ko, and uses a lot of gradients

  • mapWaadt is 260 Ko


If we skip those which use gradients, and the big mapWaadt image, the boost is closer to 35%. Not bad...

Sunday 11 March 2007

First real post

OK, so here is the first real post of this blog. Humm, but about what ? OK, let's dive in.

As you surely don't know, I created an open source project on java.net called MDIFramework. This is a full java framework for easing the creation of multithreaded swing applications.

When you create an application, you soon discover that :
  • you need to execute the lengthy methods in separate threads to avoid "freezing" of the GUI, but then, it quickly becomes a nightmare to deal correctly with the communication between the main event thread, an even using SwingWorker is not enough (for example, what to do if you want to be sure that two actions launched by the user will be executed one after another, for example ?)

  • You would like to ease the configuration of the application, an store it in the most automatic way when you close

  • You want to deal with several types of files in the application, each providing different possible actions, so you would like to have some sort of metadatas associated with each opened file

  • And what if you want to be able to use easily plugin with your application ?
So as I always copied and pasted the same sort of code to do the things above, I created this framework.

If you are interested, go check to tutorials here.

By the way, JSR 296 is already an upcoming Java JSR that aim to provide a simple application framework for Swing applications. I did not knew that when I created my project (but also JSR 296 is still very young), but I think that what this JSR provides (you can check the still evolving open source implementation here) is different. I should try it, and maybe add some JSR 296 capabilities to my own framework... (yes I know, why recreating the wheel when it is already existing ?).

Saturday 10 March 2007

First post in another world

Hello !!

I have already another blog on this address : http://rimmedwithfire.blogspot.com/, much, much more metallic than this one... but I would like to blog from time to time about programming, open source stuff, and things like that, so I choose to create this another one.

Hope it will be updated regularly (this is the case for the moment for my another blog).

See you !!