windows vista delayed = Mr Smith

You prolly saw it in the news but windows vista is delayed. My first reaction was, So what, that has happened before, right!? Well guess I was wrong, yesterday evening I was watching CNN and there was a big report on this event. They were questioning Microsofts competence, questions like

  • have they lost their position?
  • can’t they do something easy like an operating system?
  • Are they going under because the company is just to big

The stock of microsoft were already starting to lose ground, it was even taking down big companies like dell with them. So Mr. Dell if you read this, start your linux assembly line please (stop saying it, just do it!!) 😀
They also pointed out that because Microsoft wouldn’t get it out before christmas they would lose all the revenue that came with the christmas sales and that would be a great setback.
I also heared on my podcast (where else) that IBM wouldn’t be switching to vista, but would turn their whole company to redhat (or fedora don’t know exactly). Just imagine that all those fortune 500 companies would do that, first off that would give microsoft a real backset. Secondly they would probably use openoffice, so If they would send a document into the world it would be a pdf or openoffice document type. So every customer of them would have to download openoffice to open and edit/read it. Just imagine the snowball effect this (w)could have. These are exciting times I kinda feel like the first matrix flick when neo is becoming The One, I for one am quite sure that linux is The One (kinda lost all my selfrespect of not being a total geek by this last sentence, but one cannot deny his true self, right?!)

Well maybe the shot we have with the new gnome and kde desktops is bigger than everybody is hoping for. I sure hope gnome will get further than has been planned, I’m really pleased with the outcome of the 2.14 version. It’s really blazing fast, I don’t have Xgl turned on all the time because my hardware isn’t fully supported yet, but even with Xgl on its fast (sometimes even looks faster with xgl turned on than off :D)

Oss reflection

Today while driving to work, I was listening to my podcast (off course) and got to think about the future and the impact opensource will have or maybe already even has on the business. Because opensource means free in many different forms, I’ll point out that I mean free as in no license fees.

Well I know from my former Job that a lot of the deals we made were because we were cheaper than our competitors. But that didn’t mean we were cheaper work forces, no mostly it meant that our sales guy did a good job getting the license fees down. Yeah, why else would you need a sales, right 😀

Well if more and more applications become opensource (and that’s the way we’re evolving imho) those tricks, won’t cut it any more. We will then have to persuide the customer off our skills and show them why we are better than our competitors or tell them why they should pay us more. I think that’s the way business should be done, now-a-days to many products get sold because their marketing team is better not because their product is better. Somebody once told me Oracle runs best on powerpoint. Now I can’t say to much about oracle because I don’t have that much knowledge about competitors in the same league. Mysql is nice, but you can’t compare it to Oracle (but version 5 is coming close).

Prolly the future isn’t going to be as black and white as I see it, but I hope it will change more to what I described here. I’m not saying everything should be opensource either, I’m just saying clients should have the best person for the job. If somebody’s better than you and asks the same price for his services, he should get it. If you get the job because you cut a better deal with the reseller that’s not right in my eyes, but then again I’m no suit.

Gnome 2.14 + Podcast review

Yesterday evening I did an apt-get dist-upgrade (Mabye upgrade alone was enough, not quite sure. For the moment I mostly do dist-upgrade, if there is no dist to upgrade it seems to fall back to the normal upgrade).

48 MB to upgrade, that seemed a lot,off course upgrade. Today I logged in and checked the about gnome dialog. It seems 2.14 has arrived on my ubuntu dapper drake. Haven’t noticed that much changes to the 2.13.9.? I was running before. So I’ll reread the release notes 🙂

Yesterday evening I was talking to a client and the popup came that new updates were available. He’s a microsoft guy, so I explained him a bit about what the updates and all were all about. I explained to him, imagine that microsoft would popup something saying, we have a better and newer version of the kernel, drawing dll’s,… He said, well they do that, that are the service packs. Hmm I wonder, Windows xp is out around 2001 – 2002, right? There are 2 service packs available. Just imagine that on linux. My guess is, we would be still running 2.4 or 2.2 kernel. Okay I know there are still companies out there that prolly run a 2.4 or a 2.2. But they have the choice to upgrade and off course, linux fixes it own problems you don’t have to buy other software to protect you from bugs they can’t or won’t fix.

Makes you wonder if microsoft would go as fast as linux is going at the moment. Or would the bad rap still stick and nobody would join? That is off course if there were people who had the knowledge,brains and will to understand the source code of microsoft.

On another note, I was listening to my daily podcast during my commute from Bree or Leuven to Diegem (Brussels). On the linux link tech show there was the head of open source of sun. At first they off course made some jokes about sun and opensource, but in the end it got really good. I especially liked a part that goes something like this.
Sun donated openoffice to the community. First they bought the company that was working on the source and afterwords they just gave it away, now why could a company do that?
Well, imagine this: Sun has more than 100.000 employees wolrd wide, they were all using microsoft office. The costs of linces compared to the costs of buying the company that was working on openoffice were more favorable to buying the company. So we bought the company and released the code.

Now that’s something I really dig, why aren’t all big companies like that? We would have a lot more good opensource software.

He afterwards did admit that sun had a bumpy ride. He pointed out that sun first started as a real opensource company, but due to a lot of factors they weren’t as openminded as in the beginning, but now they were again focussing on opensource and we would see more news of sun in the oss community. He even said that the sun jvm would become opensource, unfortunately he didn’t say when.

So go over to the linux link techshow site and download their podcasts, they’re really good and very informative!!

Never put an image (or static file) into a db

Here’s a nice article on what exactly happens if you put static content in a database. Okay, it may look nice and stuff, but just check here what actually has to happen to just serve that static file.
Just a confirmation of what I’m always saying to people who do want to do it! So read it, if you want to store or in a former project stored images in the db!

reading kernel development by robert love

Last week I spent a week home, call it vacation if you wish. Other years I was always very busy doing all kind of geeky stuff, you know what I mean, right? Well, this year I wanted to really do nothing and just reload my batteries and get some extra sleep (in my normal life, i sleep about 4 hours a day).

Because I didn’t want to spend most of the time behind a computer, I picked up a book a had bought half a year ago. The book is kernel development by Robert love. I’m only at page 40 or something, but I have to say I already learned a lot. Because i’m always programming in higher languages you tend to forget sometimes how the underlaying system works. Because you are used to programming to a virtual machine, you don’t have to think about freeing you objects and how your datastructures are aligned,…

Reading the book I came to think about how different those 2 kinds of programming really are. I wonder if there are people around who like both, philip probably does, but for the rest I don’t actually know people who love the beauty of low level programming as wel as high level programming. To bad I haven’t got that much experience in the low level field. Besides a small patch in liferea and a patch I’m working on at the moment, my ansi C knowledge isn’t that great :s. Besides if you want to do kernel programming, you don’t have glib available and if I remember correctly you don’t even have libc available?!
Who knows, maybe after I’ve finished the book I’ll give a custom kernel module in a xen environment a swing, I’ll call it the helloworld-module or foobar-module 😛 and I’ll finally test out the remote debugging philip is always bragging about 😀

working at google sounds nice

I went to fosdem as I said, heared some good talks, on of them was the talk of Jon Trowbridge. He’s really hilarious, the one joke that stayed with me all this time, wasn’t really a joke but an anecdote.
As you might know, Jon stopped working at novel and went to google. He couldn’t say much about his job, but he did say this:

If there’s one reason why you should come work for google it would be that every developer get’s 2 24 ” tft’s to program on!! If I come home my 21 ” tft seems so small!

Now why don’t all managers think like that? That’s why I would never buy a laptop with 1024×786 resolution, once you’re used to programming on a bigger resolution, or even worse dual screen your really stuck. That is, if you use it the right way. Have your documentation,UML model, DB,… open in you other screen and are developping in your current screen. There are off course better reasons why it’s handy …
Okay I know, everything you can do with a dual screen or high resolution you can do on a small resolution 2, but hey I’m a geek and I like to do geeky things! 😀

Fosdem + java podcast

This weekend I’ll be at Fosdem, I’m surely going to follow the voip track. I’ll be viewing following Damien’s about Ekiga, and off course Mark’s talk about Asterisk.

I also want to say thanks to Tom for his blog entry about a java podcast. Tom if you read this, is there a backtrack option on your website, couldn’t find it in the comments, same goes for Damien actually?
Up until now, I’ve only listened to the javazone’s podcasts and viewed the jboss podcasts. When I’m done listening to my current compilation of lugradio/linux link tech show, I’ll burn some java podcasts and start listening 🙂
Does anybody know a good site about OSS/programmer podcasts podcasts planet, hmmm I wonder if that’s a good sentence? 🙂

Mono/glade app did the job

A while ago a wrote about a mono app I was busy developing. Well this weekend the event took place where my app was used. And expect one little bug in the app (my fault) it worked very very good! Everyone was pleased with the result.Let me explain a bit about the event. It’s called 6 uren loop van zolder (dutch) in english this would translate to something like 6 hour run of zolder , as you prolly guessed its about a group of people running 6 hours 🙂

So these people run laps around the race track of zolder. One round was 3930 meters, I had designed an application that would let them insert new runners but more importantly it was made to keep track of how many laps a runner did. So we set us up in a little box at the start/finish line. Everytime someone came along they yelled the number of the runner and we had to insert it. Not so difficult you would image, right. Okay but imagin this, those runners sometimes stay in groups of 20 people. And all those 20 people come by you have to insert them, believe me the first couple of rounds it was really speed typing and mistakes were not so easy to fix then because the lack of time. At the end reports had to be generated for every category with the best results frist, bad results last. (if you can say that 50 km is bad 🙂 )

How did I do this, well first off this application had to run for 6 hours and had to be pretty stable so linux was off course my prefered choice of OS 🙂

Now I had to choose what language to do it in. Okay for work I do java, but I like to use other languages as well. I have done some project in dotnet in the past, but not yet on linux using mono. This was the best use case I could imagine. I had already played around with monodevelop in the past, so my choice for IDE was easy too. (I also wanted to try out the new version with the plugin system).

Because I really hate writting DAO layers with their CRUD statements.
(CreateReadUpdateDelete)
I used Nhibernate for doing all the Data Access. I’ve used Hibernate frequently in my java projects and wanted to know how far the dotnet/mono version got. I must say they did a pretty good job, only thin that didn’t work for me was the mapping in custom sql statements. ie. You have an object Runner with a property StartNumber that maps to a column Runner_Id, if you want to use it in a custom sql query, you would have to do something like “from Runner order by Runner_id” and not “from Runner order by StartNumber” as is in the java version and what you expect it to be. But hey maybe I didn’t check it good enough, and I didn’t get the CVS version.

Okay a Little example of a hibernate setup:
the mapping file

<hibernate-mapping xmlns="urn:nhibernate-mapping-2.0" assembly="6urenloop">
	<class name="Categorie" table="categorie">
		<id name="CategorieId" column="categorie_id" type="int">
			<generator class="assigned"/>
		</id>
		<property name="CategorieName" column="categorie_name" type="String"/>
	</class>
</hibernate-mapping>

The Mapped object

// created on 1/25/2006 at 11:53 PM
using System;

public class Categorie
{
	private int _categorieId;
	private String _categorieName;
	
	public int CategorieId
	{
		get{return this._categorieId;}
		set{this._categorieId=value;}
	}
	
	public String CategorieName
	{
		get{return this._categorieName;}
		set{this._categorieName=value;}
	}
}

The Dao

using NHibernate;
using NHibernate.Cfg;
using System;
using System.Collections;
using System.Reflection;

public class CategorieDao{
	private ISessionFactory factory;
	private static CategorieDao _instance;

	private CategorieDao(){
		this._Init();
	}
	
	public static CategorieDao Instance{
		get
		{
			if(_instance==null)
			{
				_instance = new CategorieDao();
			}
			return _instance;
		}
	}
	
	
	private void _Init() {
		factory = HibernateUtil.Instance.Factory;
	}
	
	public Categorie FindById(int id)
	{
		ISession session = factory.OpenSession();
		ITransaction transaction = session.BeginTransaction();
		IQuery query = session.CreateQuery("from Categorie where Categorie_Id = :id");
		query.SetParameter("id",id);
		IList list = query.List();
		Categorie cat = (Categorie)list[0];
		transaction.Commit();
		session.Close();
		return cat;
	}
	
	
	public IList LoadAll()
	{
		ISession session = factory.OpenSession();
		ITransaction transaction = session.BeginTransaction();
		IQuery query = session.CreateQuery("from Categorie order by categorie_name");
		IList list = query.List();
		Console.WriteLine("list size : "+list.Count);
		transaction.Commit();
		session.Close();
		return list;
	}
}

Pretty straight forward right? As backend database I used mysql. I know there are other people running windows who want the results, this way if they setup a mysql on their windows they can import my tables.

I used 4 tables:

  1. Runners
  2. Categories
  3. Laps
  4. Results

The first 2 are obvious, but the laps table is a table with 3 columns

  1. runner_id
  2. max_lap
  3. timestamp

Every time a runner passes our box we would insert his startnumber, in the end we can track every runner his laps. This way if there are any wrong entries you can quickly fix them withou

Another thing that was pretty strange in my eyes was getting the selected value from a TreeView the code goes like this:

TreeModel model;
TreeIter iter;
if(this.CategorieLst.Selection.GetSelected(out model,out iter))
{
	newLoper.Categorie = (int)model.GetValue(iter,0);
}

With my java background it’s not that obvious, even in my dotnet projects I haven’t seen a construct like this. However in the C language it looks normal 🙂 Guess this is result from binding a C object to C# object. But it works, that’s what matters!

I used glade-2 to create the GUI (as is the standard for creating Gtk applications). I used the glade bindings to connect my gui to my code with the simple lines of code:

Glade.XML gxml = new Glade.XML (null, "6urenloop.glade", "window1", null);
gxml.Autoconnect (this);

And giving my widgets the same name as in the glade file,adding the xml attribute [Glade.WidgetAttribute] is all that is needed. Easy isn’t it?

Here you can find some screenhosts
The screen for inserting new runners:

The screen for inserting laps and creating,exporting the results:

I’m going to make some small adjustments, refactor to use english variables and not dutch variables. Have a GUID for every lap to make updating the laps easier. Once that is done I’ll post it on sourceforge and everybody who does something like this can reuse the code base maybe even update it. You can even check it out for Nhibernate, the documentation of NHibernate isn’t quite as good as the java version.

Ps yes I know, the interface is very ugly and not following the Gnome Guidelines, but it works like a sharm.

waiting

I always found it a pitty I hadn’t ordered a Nokia 770, I’m still considering getting one, but they cost a lot of money, if they had a built in cellular, I’ld probably had one by now. But wait what’s this, hmm a newer version coming up. Definitely got to keep my eyes on this one. O Wait, one of those guys is coming to FOSDEM if I’m not mistaken, hmmm. Maybe ask a question about it??? Sounds like a plan! 😀

Hmmm in the same category is this item , what’s sweet is the little additional comment about gnome. 😛
I’m still waiting for the first real cellular with PIM functionality running linux!! Does anybody know one? Give me comment would ya? thnx

Bad week

Don’t you sometimes know, you’re gonna have a bad week? Well I do, and I’m going to get one now. I bought all the components for a new computer to sell to a friend. First of he had to week more than a month because the stupid supplier couldn’t ship the ligthscribe dvd burner, I got sick of it and bought one myself.

Sunday evening I started putting the computer together, I booted and all seemed normal except I didn’t get see the BIOS, hmm that’s strange, unscrewed the motherboard and all the components placed only cpu, cooler, memory and graphics card in there, same thing, hmmm very strange. Okay removed every component, even cpu and cooler checked the contacts of the cpu, put all back together, no luck, tried other videocards I had lying around but always the same.
Monday evening tried it again, I had to be at my friends house at 8, would I get there in time? Nope, still same problem. Pfff, I called my friend and told him, that probably 1 of the 3 major components was broken and it would probably take another month to deliver them. So he could best just forget about this computer and order one from another store, otherwise he would have had to wait over 2 months to deliver a computer.

Lessons learned from this?? Hmmm always have a small stock in house 🙂 So my next invoice will probably contain some cpu’s,mobo’s,mem’s and graphics cards. I already made a small calculation and all seems possible, but still have to check with my accounted.

Not much programming the last couple of days, except off course in my day job. But that’s not to hard, the base platform is finished, all the needed services,dao’s are in place and the first product has been implemented in the struts layer, now final tweaks and first deployment.