Configuring Mutt

These days mutt is my default email client. Even though I still use webmail for my service based accounts (gmail, yahoo) and Evolution at work I would one day like to merge all my accounts under one roof with IMAP, spam control and mutt as my ‘Mail User Agent’. The first thing which I wanted to do with my mutt was to make it send PGP-signed messages. I found the following links to be interesting read.

Leave the first comment

Moving to Xen, maven jetty works now.

I requested my hosting service to migrate my virtual private box from a User Mode Linux setup to a Xen setup. Xen seems to be the de facto visualization solution for Linux. It has become a considerable part of new Red Hat Certified Engineer’s exam as well (for which I am prepping these days). Interestingly I was having troube running jetty plugin on User Mode Linux but now I am ablt to run that plugin (jetty wont bind to port on the local UML machine, now it does).

 

Leave the first comment

Selling my car

I had been planning to sell my (crappy)Suzuki Alto VXR ,2003 to some (un)-lucky shopper. I had already put up an ad on the back of my car and received many calls. I was hoping to get 350,000 Rupees out of this car. Eventually I sold it for 338,000 Rs (roughly 200$ less than my asking price), but I think it was a good deal. The car had an accident and was not in the best of shapes but it looked ok. I will be using my Dad’s Honda Civic from now ;) .

Leave the first comment

Project Summer Hibernation

following is a repost of my SoC proposal for OpenNMS

Synopsis

OpenNMS currently still depends on some PostgreSQL-specific behavior (especially in stored procedures) which keeps it from being database-independent. Although OpenNMS has been slowly transitioning its code to use Hibernate instead of direct JDBC calls, but there is a lot of code still using JDBC. The following is a project proposal for Google Summer of code 2008 to the OpenNMS project. This document gives details of project methodology, time lines, and risks.

in short

  • The aim is to complete hibernate transition for the entire OpenNMS project. Author’s aim is to complete major tasks by Dev-Jam 2008.
  • The deliverable are code, test cases and documentation. OpenNMS installation documentation which deals with OpenNMS install with MySQL and perhaps a few other OSS Databases will be part of deliverable.
  • Applicant has been a part of OpenNMS user community for a year now and has genuine interest in Java EE software development(due to his present job and future education and career directions)
  • Applicant will be sharing code samples before project selection to show mentors that the applicant has sufficient background in Java EE software development.

Further info and code samples will be available at http://code.hatimonline.com/opennms

Who Am I

My name is Shahzada Hatim (aka geoaxis on #opennms). I am a 25 year old computer system engineer from Pakistan, currently part time certificate course student (http://www.vu.edu.pk) and a prospective Masters student for different IT programs in EU (starting in Aug, Sep 2008).I work for a small Belgian company as open source software developer. I am also a returning summer of code participant. I was selected for a project by Internet2 in 2007. I started work on the project and made some headway with it. Unfortunately timing constraints and a work emergency on my then job took precious weeks off my schedule and I was unable to deliver the project’s Midterm goals. I dropped out of the program.

Interestingly one of the things which I was involved during my work emergency was to replace Jff-NMS with OpenNMS and to use it to monitor a SAN setup (previous setup had a server meltdown causing the emergency) at a major telecoms client’s site. At that time the job I was doing was part support and part software development. Since last six months I have joined a core development company working on Java EE and specifically Spring/Hibernate. I have gained considerable know how for using these technologies.

Methodology

I am resigning from my full time position in May 2008 as I am already getting pre-admission offers from universities in Germany and Sweden. Since their course work will start in Sep/Oct 2008 I will have considerable time on my hand to work for SoC. Therefore I will have no commitments other than SoC and 3 credit hour distance education Masters level certificate course.

I would divide my tasks into practical and attainable parts along with the help of my mentor. My experience with Spring/Hibernate leads me to believe that this tasking would be trivial but it would ideally be done with deeper discussion with the mentor (before the project starts). Good thing about this project is that it can be done in small incremental steps which are virtually independent of each other and is unlike some other projects where there can be a lot of dependency on past work.

The time before SoC session 1 would be used to do administrative work and revision of technologies. The major coding portion will take place in 3 time slots which would account for 7 weeks. I intend to participate in Dev Jam through telecommute (1 week). Rest of 4 weeks are dedicated as cushion time and for testing.

Committing code in small chunks would be the best practice for this project. Not only would daily commits be helpful for everyone to ascertain the progress of the project, but also when these changes make it to trunk they will have more chance of getting tested and reviewed by OpenNMS community.

I have sufficient knowledge of Java EE to start working on this particular OpenNMS project. My preferred work platform is my 17inch Core 2 Duo, 3GB Ram Acer Laptop running latest Ubuntu Linux and Eclipe Europa with WTP. I have an optimal DSL connection at home for the purpose of daily checkouts and commits. I have my own Virtual Private Server with an irssi screen session running (and joined on #opennms) so I am always available on irc. Of course I would be thrilled to be part of the OpenNMS’s internal jabber list as well. Weekly/Bi-Weekly meetings through text or voice chat could also be helpful.

I will be blogging extensively about my development activities on my blog with tags of ‘opennms‘ and ‘soc’.

Why I want to do this project

  • Brush my Spring/Hibernate skills, Java EE skills.
  • Get up to speed with latest (but necessary) Spring/Hibernate techniques and be part of a team to design and code OpenNMs with those techniques.
  • Get a chance to contribute to OpenNMS community.
  • to get Google SoC T-Shirt.

Project Schedule

April 7 – April 21
Placing samples on-line, revising proposal, reading up texts such as ‘Spring in Action’ and ‘Java Persistence with Hibernate’

April 21 – May 25 (5 weeks)
Week 1 Finalize/Tweak Goals, Review Code to identify tasks for Slots.
Week 2-4 Learn unknowns like Maven, OpenNMS patch how-to, revise Spring/Hibernate (+ other theory like DAO pattern and how it’s used in OpenNMS)
Week 5 Complete all design aspects/discussion with Mentors.

May 26 – July 07 ( 6 weeks)
Week 1-2 Time Slot A
Week 3-4 Time Slot C
Week 5-6 (wrap up, cushion, testing)

July 7 – July 14 ( 1 week)
Midterm evaluation

July 07 – Aug 18 (6 weeks)
Week 1-3 Time Slot C
Week 4 Dev Jam
Week 5-6 (wrap up, cushion, testing, finalize documentation)

Aug 19 – Aug 25 (1 week)
Final Review

Deliverable

  • Complete Hibernate Migration with DAO and Service (mock) tests.
  • Running OpenNMS on MySQL only (and perhaps some commercial database like Oracle or MSSQL)
  • Replace all stored procedures with equivalent constructs (in terms of relative performance)
  • Documentation and tests to accompany code (an embedded DB would be used for persistence tests).

Bonus Goals

Since major portion of OpenNMS code will be reviewed, I am also suggesting that code overhaul with respect to spring framework can be a bonus goal. This could include useage to latest Spring 2.5 techniques and annotation based Hibernate mappings.

One tangible bonus goal can be to benchmark the performance of OpenNMS after code changes. I am confident that there won’t be any negative
performance impact but it would be good to have statistics. For this open source Java profilers may be used. This is strictly in the case
where all tasks are done well ahead of schedule.

Risks

Every project has some risks involved. It is wise to identify them first and follow a strategy to avoid them.

One risk could be any prior commitments which cause hindrances in SoC. Since last year I got stuck in a work related issue which made me leave SoC, this year I am choosing to only focus on SoC (and my Summer course). I have absolutely no commitments (at least till end of August) in the coming summer

Another risk can be lack of expertise. Though I don’t claim to be an expert in ORM and dependency injection frameworks, but for the past 6 months I have been working on commercial applications which use Spring/Hibernate. I am willing to back my claims with working code which I am currently adapting to use maven and should be available on my site running under jetty—maven plug-in (similar to OpenNMS bundled jetty).

In short I am pretty confident that I am a strong candidate to work on SoC project for OpenNMS. Thank you for considering my application for your project.

Leave the first comment

Witnessing an Accident

Today started as normal Monday for me, I got up early to get in my Dad’s car only to sleep my way through the journey from Abbottabad to Islamabad (our weekly Monday ritual). We reached in time , I had my usual breakfast and hitched a ride with my Dad’s chuffer to my office as I had left my car parked there. I was on my usual route in rush hour traffic and then some thing happened which has shocked me to my core. A young boy in his teens wearing school unform was on a bus full of otehr kids hanging from the bus. The fully loaded public transport hastily sped and over took a truck. In this process the boy lost his grip and fell down on the road only to be crushed by the oncoming truck.

I just can’t describe how horrific it was. I have never seen a person die before, atleast like this.Since that time the scene of that young boy in school uniform getting crushed by a truck has been playing in my mind over and over. There was nothing any one could do. No one knew what that young student could have become had he continued his education. We probably loose so many young people this way. This was just a pointless death, So many people could have done some thing to avoid such a loss. I just can’t help but think, what did that young chap deserve to get this painful death. He was son to some one, probably brother to some others. He could have become a sole bread earner for his family, with his death so many hopes and dreams have died. It is true that you can tell the charecter of a nation by looking at it’s traffic. Our charecter can then only be described as thugs, rapists and of murderes. It was the guy’s fault too that he should have considered his own safety. But I would blame it all on the traffic police.

Why can’t Islamabad traffic police stop buses which are over crowded, ban any driver or company who violates these basics of safety. I am not talking about seat belts or air bags, I am talking about people not hanging from the roof of buses and every one having a decent seat to sit on. I am just not going to sit idle on this and will make sure that I make this case heard on every public forum.

Leave the first comment

Summer of Code Application extended

Google’s Summer of code application deadline for students has been extended for one week. It’s now Monday April 7th 2008. This is good as well as bad. It’s good because it gives me one more week to make my application even better, and it’s bad because I will be spending now more time in the application process than in actual coding

Edit:
Well I didn’t spend more time on my application, but I was able to get Jetty running through maven. Apprently User Mode Linux was preventing Jetty from binding to an IP, but after migrating to Xen every thing works smoothly now. It seems that I would also be able to run OpenNMS now :) .

I am currently following the following good links for sample application devlopemnt

http://www.lulu.com/content/1087191 (Set of tutorials to start devlopment with Spring and Hibernate using Maven2)

http://today.java.net/pub/a/today/2007/03/01/building-web-applications-with-maven-2.html (Maven 2 Web application devlopment tutorial using Jetty plugin)

I have also found the following book to be useful

Thomas Van de Velde, Bruce Snyder, Christian Dupuis, Sing Li, Anne Horton, Naveen Balani
ISBN: 978-0-470-10161-2
Leave the first comment

OpenNMS and Summer of Code

OpenNMS got selcted for Google Summer of code 2008. It seems that making enough noise on IRC and mailing lists does work :) . I have also got my slef registered as a part time student in Virtual University of Pakistan as a Masters leve certificate course student, so it seems that pieces are falling into their places. I am thinking of applying for OpenNMS hibernate implementation coding. Right now I am just applying and I have hope that I will make it. But unlike last year I think I better take some time off from my full time job as I wont be able to juggle between job, course and SoC. For now I better post samples of hibernate coding on my site (possibly running under jetty)

 

Leave the first comment

Friend’s Wedding

A friend of mine got married this month. His marriage brought unnecessary pressure from my parents on the subject of my own sentecning :) I told them there is time for it and ofcourse I don’t have time to find the girl (with all the procastinating I do). Any who this was the first ever complete Pakistani marriage I have attended in my life. I went to a pre-Mehndi function, Mehndi, Barrat and Walima. The highlights were meeting few friends after 5 years and sharing old memories.

Here are some pics from different events.

Leave the first comment

Red Alert 3

I found a link to screen shots of Red Alert 3, it looks stunning. Red Alert was my favourite game  back in the day when I was a hard core gamer. I have been in retirement since last 2 years , but this title may lure me out of retirement :) . Now I also have a Vista box with me which could run this game, but I would like to play this title on PS3 instead.

Leave the first comment

Acer Aspire 7720-6604

My Acer Aspire 7720-6604 , running ubuntu Gutsy

more pics here

A friend of mine who was coming to Pakistan from USA for vacation was kind enough to order an Acer Aspire 7720-6604 laptop from newegg.com. I have previously used newegg.com and like their service. Initially I had waited for the launch of Apple Mac Book Pro with Penryn processors, but after the launch I was not very impressed with the specs. It was same MacBook Pro with a little better processor. I searched for the first few laptops and decided to buy this Acer machine for my self.

This laptop comes with Windows Vista Ultimate and an HDMI connector, but it does not come with a BlueRay. I am suspecting that with the recent news of impending demise of HD-DVD, upcoming high end Acer laptops will come with BlueRay as an option.

Overall I am satisfied with this laptop. It has a nice exterrior and an OK interior. Its finish is not as bad as it looks in the pictures. The real deal is in the specs. It has whooping 3 gig of RAM. I have nver worked on a machine with this much RAM before so it would be intresting. It also has 512 MB Geforce 8600 GT graphics card which would be very good for PC gaming. But I am no longer interested in gaming.

Windows Vista comes with trail/crap ware, alot of games from Oberon media with 60 minutes demo. The first thing I did was to uninstall them. They left their shortcuts, which I would delete once I log back to Windows. Windows Vista has neat looks, but Ubuntu’s compiz is way much more configurable.

After having few hours with Vitsa, I wasted no time and installed Ubuntu 7.10 Gutsy on to my machine. Apprently the 64-bit version of live CD was not able to work properly so I selleted for 32-bit one. Every thing worked fine except for sound driver. The sound card in this particular is based in intel high definition audio. I tried few Ubuntu recipies here and there, but I guess the real problem was that snd-hda-intel module had to be loaded with correct parameter, which was essentially one small line at the end of /etc/modeprobe.d/alsa-base

options snd-hda-intel model=acer

I chose for Ubuntu (and not Kubuntu) because of its better integration options (in terms of compiz and multimedia). I plan to make a Gentoo machine out of this laptop, but frankly Ubuntu fulfills most of my needs.

As for the bads of this laptop, I really don’t like its keyboard. Perhaps it is because I am used to keyboard of previous laptop. Also this laptop get heated to some extent. I always thought that upcoming chips would probably produce less heat as they consume lesser power, but it is almost the same. I would recommend and one who has a need for a serious devlopment machine to get this laptop. I actually got it for a very good price (1368.51 US$, or around 83000 Pak Rupess at the time). Hopefully this laptop would be a good investment.

Leave the first comment