29 June 2005

Nokia 7710 Annoyances



I have been using the 7710 for over 2 months now, and am generally happy with it. However time after time, there are several annoyances keep popping up and really needs Nokia's attention to fix. Here are some of them:
  1. Response is slow between windows.
    Clicking between windows, Opening SMSs, Documents and File Browsing, it just takes time. like 5-10seconds. Which is really annoying, especially when you just want to reply a quick one word sms.
    More of this in subsequent points!
  2. SMS app (Messaging) is underfeatured
    Perhaps its because SMS or Text Messaging as they call it in the West is not popular, but here we use it alot. And Nokia needs to work on their SMS app, because its just too plain.

    • Replying SMSs - It lists the SMSs, time and the sender, but on the fast keys it just has 'New text message', 'New E-mail' and 'Delete'.
      I find that I use 'Reply' a whole lot more than 'New E-mail' or even 'Delete'. Yes, you can actually customize the side buttons, but 'Reply' is not an option. Duh.
      So now Ive to either call the menu, click 'Message' then click 'Reply' or Double click the message, wait 5 secs for the message to appear, then click 'Reply'.
    • To: - The default key input for the SMS To: field is set to number input. That is correct, if we were using this like 10 years ago. Now we dont need to know about numbers, most of our contacts are in the SIM already. I would like it to be alphabet input by default.
    • Slow slow slow - As in the first point, after entering the text, sending, where the phone resolves the numbers is slow... about 3 seconds for each contact.
    • No threaded view - I saw someone using the Treo 650, and was impressed at the way it handles messages: it threads the conversation ala an Instant Message app. This means meaningful conversations can be stored in context and threaded away. So nice. I wish Nokia can do the same.

    What I like about it is that its easy to chain up multiple recipients to the SMS. Also the Delete is good: just multiselect and clear the trash.
  3. Needs a reboot once in a while
    Its true. To make sure that this phone works, it needs to be rebooted in like once every other week. Not just a Power Down and Up again... nooooo, you will have to remove the back cover, take out the battery, pray to the Norwegian Gods and replace the components. It doesnt help that the plastic pieces are manufactured to such high precision that its impossible not to cringe at the creaking sounds as I pry open the parts. Its a scary thing.

    Things which recover after a hard cold reboot are:
    • No ring tone when someone calls. Yes, a day went by when all my calls were missed because the ringer didnt work! No, its not because I put the Profile to Silent or something, I made sure that it was set to 'General' and even tested the music which played OK (with vibration)! Bizarre.
    • Images refused to load. After a while, especially when you are showing off some pictures you took, the Image Viewer app will refuse to load up the JPEGS. It will say something useful like 'Image Format not supported'. WTF? It worked before! You want this to work? Reboooot!

  4. Alarm Clock Interface
    The Alarm Clock is really nice. Ive chosen a nice tune which is melodic, and gets louder if you dont turn it off. The problem is that to turn of the alarm, you will need to press 'Off' on the touch screen. And guess what, overnight, the screensaver will be enabled, and you will need to disable it by pressing a two key combo which can only be done with two hands.
    This sux especially when you are groggy and bleary eyed. Who came up with this UI Design?
    Heres what Nokia can do: Disable the screensaver. In large buttons, have 'Snooze' taking up 50% of the screen, then 'Stop' (40%) and finally the smallest button of them all 'Mute' (10%)

    (That being said about the screensaver, SOMETIMES it gets disabled. Other times the it doesnt, and thats when things gets frustrating)
  5. Laggy Picture Taking
    It takes ages to take a picture. The time between pressing the 'Capture' button and the actual picture taking is very variable, sometimes 1second, other times 10 seconds! So dont think of using this camera to take action shots. Frustration!
  6. fullstops Always become backspaces
    The Handwriting recognition applet is cool, it works for me 90% of the time, but the other 10% is pure hell. The worst is when I need to write a fullstop: '.' This is done by tapping the screen to draw the dot. However if you dash it out, it will be a space. Thats fine. But in my efforts to write a dot, the stylus tends to go backwards, and that signifies a 'backspace' which deletes the previous character! argh.
    Something like Palms multi alpha-numeric-case-symbol input pad would be great.
  7. No Wifi
    This was the single most reason why I didnt get this device earlier. If it wasnt for the great deal, I would have waited out another year or so. Yes, I wish Nokia would have a wifi module for this phone.
  8. Size
    Yes, of course.. its big. Slightly thinner would make this perfect.


The Firmware can be retrieved by sending '*#0000#' to the dialer, and mine is "V.03.26.0 15-02-05 RM-12 (c)Nokia"
I just hope there is a new firmware out there soon, cos this is driving me bananas.

Otherwise its a darn good phone! Seriously:
  1. The Pictures are really clear (for still pics),
  2. the sound is great, especially when playing back MP3s via the loudspeaker,
  3. the internet browser (Opera) is great at scaling the fonts,
  4. picodrive works OK! (NBA Jam woohoo!)
  5. Fullhand casino. the blackjack is good.


Here's a blog just on the 7710: French Fanblog on 7710 (translated)

27 June 2005

Planet MYOSS - feed me!

Hello Planet MYOSS!
Colin was kind enough to add me as a citizen of the MYOSS planet.

However I had several problems with the formatting of my feed, for some strange reason, the html went awry and basically mutilated the tags. This had an unfortunate side effect on the planet as it 'corrupted' other peoples posts with the <pre> tag. Sorry guys, downtime was only 2 days :-[.

This was using the atom.xml directly via:

http://yoonkit.blogspot.com/atom.xml

I did a google on atom and rss and found this online converter,
and I passed it on to Colin:

http://www.2rss.com/atom2rss.php?atom=http%3A//yoonkit.blogspot.com/atom.xml

So what this does is that it converts the atom type feeds into rss, which I thought was great until it got plugged in:
  1. Its not 'free', so the first post would be an advertisement, and thats not so appealing (especially for an FOSS site ;-)
  2. Still some formatting problems from items from blogspot. I suspect is when I swap between the straight html code to the 'composer'/wysiwyg editor.


I inspected the output of the atom.xml in the webbrowser, and it did suggest to use Feedburner, so I made an account, and set it up to do the conversion between atom to rss. This provided better results:

http://feeds.feedburner.com/yoonkit

All the formatting came out right, its relatively fast and so far it looks like its a 'free beer' service.

So for those of you out there using blogspot/blogger.com, if you need to feed off simple rss, I'd recommend feedburner. If you have the dosh, you can pay them and get statistics of your feed, etc. but I dont find it useful...

yk.

24 June 2005

Microsoft and Mono

Very interesting. I had the opportunity to speak to a Microsoftie yesterday and he happened to be one of a PhD researcher for Mercury of which generics was one of the features which was absorbed into C# and only now available for general use.


Discussion was good, and I naively asked him what he thought of Mono. He became uneasy, but then brushed off their efforts as "they are too busy copying everything Microsoft develops and wont have enough time to innovate".


I pursued and suggested that for the sake of PhD research, how does he feel in contributing to their project just for feedback on their implementations? He said no, he probably will not do that, and added that he doesnt trust the maintainability of the mono project as after all it is based on volunteers who need to scratch an itch and after the itch has been scratched, it will not be maintained well.


I left it at that, and eventually during the course of the meal, I then understood why my questions were "inappropriate". I was actually speaking to the new Manager incharge of MS Developers tools. So its in his entire interest to downplay the mono project. Ah well, I live and learn I guess. Sorry, Tyson, for bringing it up.


On a relevant note, eweek has just reported that Microsoft Puts Roadblock in Front of Open-Sourcing Avalon and Indigo. Basically it says that for the mono project to (re)implement Avalon and Indigo, they will need licenses from MS. All for the sake of 'Intellectual Property'. They are not really clear on what aspect of intellectual property, because its not copyright (code will be written from scratch), software patents (maybe, but which ones?) or ...
"Intellectual property is something any cloner needs to think about,"
said a Microsoft spokesperson.


Which is very similar to Tyson's concept of what the mono project is. They think its a one to one carbon copy. Unfortunately its not really, as many intersting things are being done in mono. For example an entire opensource stack for developing apps based on Gtk. Interesting apps like beagle and others.


So is mono still a patent landmine for Novell? Probably, but given enough effort, prior art and geographical locations, the patents might just dissapear. Plus its still a very good platform to develop in.


yk.

22 June 2005

TMNet Horror 1.12 - How to make a good thing bad.

Oh boy, what a ride... Heres my response to them.

From: Yoon Kit Yong
Reply-To: Yoon Kit Yong

To: TM Net Customer Care Support

Cc: yoonkit@streamyx.com, shahrir@cfm.org.my, fomca@fomca.org.my, suganthi@cfm.org.my
Date: Jun 22, 2005 11:48 AM
Subject: Re: Streamyx

Hello Rafidah,

Please check your records regarding the status of this query,
and discuss the matter with your colleague G Pragash,
as I have already indicated my dismay on the small rebate sum
you have indicated.

You can read the discussion here online, as I have blogged it.

TMNet Horror 1.9 - Other rebates denied.

I then asked for your justification here:

TMNet Horror 1.10 - Gimme Gimme Gimme

I did not receive any reply,
but I was pleasantly surprised when I
received my May bill,
and there was a deduction of over RM800! You can see the bill in its
entirety here:

TMNet Horror 1.11 - Redeemed!

I was elated, and I considered the matter closed,
giving kudos to your team for finally coming to your senses.
I was even thinking of upgrading to the RM66 package!

Now with your latest email, I really pity the state of your company.

The worst is your lame "Firstly, we apologise for the late reply."
What do you actually mean by this?
Do you really feel sorry that it takes you 2 whole months
to reply my simple request of just acknowledging receipt?

I requested:
>> Can you at least acknowledge receipt of the emails I have been sending you?
>> At least within 2 working days, Im sure thats not too unreasonable?

So it looks like 2 working days in some inefficient companies are equivalent to
2 actual months in real life!

You are getting an earful here because I consider your email
rude, unprofessional and totally unecessary. I think its totally
justified. Here's why:

> Referring to your email , we would like to informed you that your rebate had been
> reflected on your Streamyx bills was dated 24th of May 2005 ( RM 422.71 ) .
> Your outstanding till to date are RM 131.22 please refer to our website at
> https://tmbill.tm.net.my for further information .

I did receive my May bill, and I did see the rebate. But what is puzzling is
HOW did you get the value of RM422.71? because the bill clearly states,
and Im looking at both the online and printed versions of them, RM845.42!
I can still see the figure on the online version, and it has passed 1 month
as there has been no changes on your end.

I feel that that is the appropriate amount to deduct considering the unecessary
overcharge, the months which I had downtime and had to pay for them, and
this ridiculous level of customer service!

Here's why I think RM845.42 is justified:
TMNet Horror 1.8 - Victory has a bitter aftertaste.

> We hope the above reverts to your query.
> Should you require any further assistance,

> please feel free to contact us at streamyx@tm.net.my or call us at 1-300-88-9515
> (from 8:00 am to 12:00 am ~ daily).

No, the above does not 'reverts my query' and you should amend the line to say:
"Should you require any further assistance, feel free to contact us at
streamyx@tm.net.my and be prepared to wait 2 months for more abuse"

> Thank you for being our valued customer.

It is obvious that your company does not value its customers.
The fact that you treat us so badly and do not respond to them
in a timely manner is proof that this statement is insincere!

Please Rafidah, solve this problem, and lets get on with our own seperate lives.
You have managed to convert a "somewhat satisfied" customer back into a
"VERY dissatisfied and angry" customer who would rather NOT be your
customer if he could.

Please acknowledge this email that you have received it IMMEDIATELY.
Please forward it to your superiors, all the way up to the CEO.
I want your top guys to look into this, and see if they have the
same concept of customer service as the people I have been dealing with.

So I expect at least 2 superiors CC'ed in the next response I receive.

Sincerely,

Yong Yoon Kit.
- Dissatisfied and getting angrier.


As you can see their customer service levels is totally non existent, their billing system is completely haywire and basically their product is substandard. What can I say?

yk

ps. I've changed back the description of this blog to this:
A Simple blog. Currently just to gripe about stuff, namely TMNet, Malaysia's premier ISP

TMNet Horror 1.11.2 - It rises... again!

OMG, just when I thought it was all over (TMNet Horror 1.11 - Redeemed),
I got a new email from them today:

From: TM Net Customer Care Support 
To: yoonkit@gmail.com
Cc: yoonkit@streamyx.com, shahrir@cfm.org.my, fomca@fomca.org.my, suganthi@cfm.org.my
Date: Jun 22, 2005 9:58 AM
Subject: Re: Streamyx
Dear Mr Yong ,

Thank you for bringing this matter to our attention.
Firstly, we apologise for the late reply.

Referring to your email , we would like to informed you that your rebate had been
reflected on your Streamyx bills was dated 24th of May 2005 ( RM 422.71 ).
Your outstanding till to date are RM 131.22 please refer to our website at
https://tmbill.tm.net.my for further information .

We hope the above reverts to your query. Should you require any further assistance,
please feel free to contact us at streamyx@tm.net.my or call us at 1-300-88-9515
(from 8:00 am to 12:00 am ~ daily).
Thank you for being our valued customer.


Regards,
Rafidah
Customer Care Support, CRM
TM Net Sdn. Bhd.
Website: http://www.tm.net.my


In response to the email I sent them on the 27th of April 2005. (TMNet Horror 1.8.1 - Oh Boy, Here we go again...)
2 months! its a new record!


I dont understand it... what is WRONG with them?!!

21 June 2005

getting Sendmail to send fast

Just incase I forget again, Id better document this down.

Configuring sendmail can be quite convoluted. We had to redirect some emails and we just hacked up a linux box with sendmail on it to do the redirection. Unfortunately for some strange reason, mail delivery was really slow, so the web-app which sent the emails started timing-out.

On further investigation, an email will go through, but each time it logs onto the mail server it takes ages (10secs) to start the communication.
telnet smtpserver 25

First thing of course was to make sure that the server was Queueing the emails, and sending them in the background. I used webmin to check that this particular Sendmail Option was set.
That was set; no problem. Then I did a telnet to the host, and sure enough the ESMTP prompt only appeared 10 seconds later.

Googling brought about several pages on identd which we should set to 0s, as the timeout for identifying was by default 90seconds. However I noticed that the FEATURE for this sendmail option was set to 0secs. So that wasnt this problem.

I checked and double checked the host file so that the server was correctly defined with the appropriate IPs, but this shouldnt matter, as when I 'telnet localhost 25', the SMTP prompt appears instantaneously.

Then there was something about bypassing DNS lookups with this 'feature':
FEATURE(`accept_unresolvable_domains')

I plugged it in, recompiled the sendmail.cf, and true enough, remote sending was real quick. However its not acceptable for this servers configuration, as spammers can use my server to relay junk. So the way around it is to make sure that the remote sender is resolvable. And that is to make sure that they are listed in the host file, or better yet, in the local DNS.

And thats all to it! Add an entry of the sending machine in the local DNS server, which your sendmail server looks up and the IP can be resolved to a domain pronto, which means fast email sending...

What a roundabout way of configuring emails... but darn satisfying when done right.

20 June 2005

I Harth Darth

What a great site!
Nicely drawn comics spoofing Star Wars.

e.g:


operation baby drop.


read them all here:

iharthdarth

losing my MIND

The past few months, MIND, the Malaysian Independant dotNet Developers Community Forums, have been quiet. This is a pity, because this time last year it was a thriving commune for like minded people to exchange thoughts and hang out.

Here are my reasons for why it has been losing its appeal over the past 6 months
  1. Loss of knowledgable and regular members
  2. Antiquated Forum engine
  3. MS Trolls are tolerated by the moderators
  4. People move on


1. Loss of Knowledgable and regular members
Gone are the days where we can exchange code snippets and discuss the details of the CLI, with a healthy mixture of jokes in between. Kahfui seems to be preoccupied with his new job, and Tim seems to be galavanting the region. Derek is still around, but his one liners are to few and far between nowadays. Firedancer has decided to do her dance down south.
Of course it takes an interesting topic to stir things up, but what is more important is a stable of reliable posters who would respond to things. The newbie posts are tolerable but really, we should have better quality questions, puhlease.

2. Antiquated Forum engine
The Forum engine looks old and feels old.
- There are no 'Edit Posts' feature which is not a problem for me, but evidently quite a problem for other users.
- It doesnt scale. After a while, the forum slows down to a crawl and refuses to work, until the admins have to lob off old posts to let it return to an acceptable performance level.
This is a good workaround, but its terrible as a forum, because we would want to have a more permanent record of posts, otherwise issues would be raised again and again. Having a track record is quite important. Currently it goes back to 2003.
There has been much talk on converting the server over to Community Server, but I heard that a year ago. People say, give 'em some slack, since its a volunteer effort. ... Fine, but isnt Microsoft paying for something? (MS sponsors MIND in a way, as they provide the meeting space, and they fund INETA which MIND is part of)

3. MS Trolls are tolerated by the moderators
Couple of months ago, some members decided upon themselves to post up attention grabbing, controversial but totally misunderstood posts. Because these persons was suppose to be 'well respected' in the community, and the posts were very pro-Microsoft (MIND sponsors), moderators found themselves caught in whether to moderate the posts or not. In the end, they didnt, they allowed a subset of posts to go through, which brought alot of antagonistic feelings in the community.
I'd be the first to admit it that I was involved in a few heated exchanges, as I felt that misinformation is best left to mainstream newspapers and government controlled TV stations. However I kept discussions open and tried not to sink below bridge level.
The MS Trolls have since been quiet but since their departure, they left a rank stench on where they've trodden. Their acceptance by the moderators mean that certain thoughts would be condoned, no matter how illogical they may be, just because of the 'politics' with the sponsors. As an engineer, merits on logic and reasoning should be the determining factor on whether a post is moderated or not.

4. People move on
Peoples interests and job requirements change over the months and years, and ultimately their communities change. We cant expect the same cast of people to remain at the forums; greater and better things are always attracting their attentions. Its the community which should make contributers feel that they get much more out than what each puts in.
Lately Im hanging out at #myoss, the Malaysian Open Source community via the IRC, and there is an exciting buzz to it. I dunno, but perhaps thats where I should help develop instead. People there are knowlegable, friendly, openminded and helpful. Just like the old MIND I used to know ...

yk.

16 June 2005

Wacky Warning Labels.

This is funny.

Wacky Warning Labels.

Some good ones:

In the manual of a chainsaw:
Do not attempt to stop the blade with your hand.

On a box or rat poison:
Warning: Has been found to cause cancer in laboratory mice.

enjoy!

15 June 2005

Im Listed in MyOSS

Just realised that Im listed in the United Nations Development Programme's International Open Source Network for Malaysian FOSS Contributors! kewl.

Thanks to Ditesh (from asix)

Arrr, Ye Maties (cont)

Hah, like I said a few weeks back, the BSA report was seriously flawed. The strange logic has been picked up by the Economist in this article: Dodgy Software Piracy Data (it was originally known as "BSA or just BS?; Software piracy", but I guess the Economist had since toned it down).

And there was a comment by someone from the BSA in London as well. Actually I wouldnt bet it's the real "Beth Scott" who commented, because the complaint is too ironic to be true:

SIR – Your article on software piracy was extreme, misleading and irresponsible (“BSA or just BS?”, May 21st). The headline was particularly offensive. The implication that an industry would purposely inflate the rate of piracy and its impact to suit its political aims is ridiculous. The problem is real and needs no exaggeration.

Beth Scott
Business Software Alliance
London
Anyway, Jason Shultz of Corante commented: The Economist Rails on Flawed BSA Piracy StudyEmail This Entry and all the feedback suggests that common sense is alive and well, when it comes to reports like this.

Everyone has problems with BSA's flawed methodology / maths of deriving the amount of piracy.

ah...

[Update - 20th June]

Found these great cartoons from userfriendly:



13 June 2005

Nicely formatted code.

Ah, instead of just using the vanilla <pre> tags, Ill take the extra effort and beautify my code with a code formatter.
I found a really good one here: Manoli C# Code Formatter
where all I do is just cut and paste the code.
It has some great features like alternating the colour of the lines, adding the line numbers and embedding the style sheet. Also formats for vb (yux), and xml/html.

nice.

[Update - 4:00pm]

Gah! the formats dont appear on blogspot! what a waste!

[Update - 6:30pm]

Ah, fixed it by placing the css code in blogspot's template....

10 June 2005

I Aint Fat, Im Undertall.

Went to the pediatrician and when asked if its normal for a baby not to eat for over 6hrs at night, the doc said "Yes its normal, and its also probably a good idea, because ... ," he points to his chart " ... your baby has maxed out in weight and yet his height is only average!"

Images of Garfield jumps into mind.

Anyway, he's not obese, just plump. More Marshmallow Man than Michelin Man. Anyway, its just baby fat, he'll lose it eventually. He's a growing boy! ...

8 June 2005

csopf v0.4.0 Finally out!

Heheh... for a long time I havent updated the csopf project, not because development on that project was stagnant (it wasnt! check the changelog!) but mainly because we have been working on it to make it production quality for one of our internal projects. Now that the project is live for almost 2 months +, Ive decided to release v0.4.0. [should be more like 1.0!!]

And what a big release it is!

There is a whole load of features, and I tried to list them all here.

It was really fun implementing for ASP.NET, and the features we built into the framework would hopefully be easier for developers to pick up. Now I just have to come up with some documentation and tutorials to illustrate how easy it is to create websites!

3 June 2005

Working With Gtk# - gargh!

Im converting some System.Windows.Forms to Gtk# and its downright frustrating. Not that the technology is buggy, its mature enough to rely on, but Im so new to it and not used to the widgets, syntax nor "Packing" philosophy... The worst thing about it, is that the documentation is not centralised, and the one which show most promise is incomplete gah!

A search on google reveals lots of links, but they are to unrelated languages like C++ or PHP or Ruby. Nothing on mono. The C++ ones are good, as the documentation is 60% complete, but I will still have to guess the Properties in C# when I try to compile.

Plus monodevelop is still way too slow with its code completion. Press Cntrl-Space and expect to wait between 2-10 seconds. No good!

Here are some refs which are barely useful:
Gnome.NET
The Mono Handbook
GotMono Community

Anyway, Im just dissapointed in not finding a consistent and updated referenc site for Gtk#.

[Update]

I found this more useful, its a desktop app called Gnome devhelp. Contains all the APIs necessary, but in C.
Another one is this The Official Mono Docs

2 June 2005

Enderle's at it again...

Oh I can just imagine the Rob Enderle wannabe's quoting this guy yet again, justifying to themselves that everyone knows that the Linux community are nothing more than just a bunch of mobsters...

The Most Powerful Labor Union in the World: Linux?

"For the purpose of this column I'm going to use the word "Linux" to refer to the group of people who support it and the open-source initiatives that surround it."


Im not sure why he chose "Linux" as the term to group the FOSS community... is it just to ride on Linux's current popularity, and say something controversial thus getting more web hits? Say it as it is. Its a community.
"SCO has experienced massive Denial of Service attacks, the company's customer base has been inundated, their funding sources have been strangled, their executive leadership has been threatened, and their ability to function has been almost completely eliminated."


The DOS Attacks were clearly not the work of the FOSS community, but a bunch of extortionists who do that for a living. See this article, first page, 60% down. How a Bookmaker and a Whiz Kid Took On an Extortionist — and Won. SCO's customer base dwindled because SCO themselves are sueing their own customers! Its an immediate turn off, if you ask me. No Customer = No Funding. And all this because of bad leadership in the first place. Somehow Enderle is blaming the FOSS community for chosing SCO's management? I dont understand. He must be getting it all wrong.

Next he talks about Maureen O'Gara and how now she is the victim of her own doings because of the pressures from the "Linux" lynch mob.

"In it O'Gara implied, but did not prove, that PJ worked for IBM, and in building her incomplete case she did create a powerful argument suggesting PJ wasn't really who she appeared to be."


"Powerful argument suggesting ..." doesnt mean "Ethically Correct", "Intellectual" nor "Factually Right". It means its just tabloid trash.

Then he goes on to blame the demise of LinuxWorld due to the "Linux" mob. The last time I read about this, it was the ethical standards of the editors themselves which made them decide to resign. Not because of the "Linux" mob, nor is it because of the extra hits their publication gets, but because they felt disgusted that their publication stood by a trash talker. And if anyone had a sense of responsibility, they should too. Obviously Rob doesnt.

Then he tries to thread all his arguments in his conclusion:
1) Linux community is like a Union.
2) Unions and organized crime are (historically) interchangeable,
3) Therefore the "Linux" community are the new mob.

A Fallacy if there isnt any... Go figure.

1 June 2005

csopf on Mono - it works!

OK, I just had some spare time, and can gladly say that Ive managed to get csopf my pet project to compile with Mono in Linux! Fortunately Ive seperated the UI junk from the Core of the framework so I dont have to totally rely on the progress of Mono's System.Windows.Forms.

What Ive done is to compile the csopf.Core into csopf.dll, and the csopf.Data into csopf.data.dll. With these two dlls, I can write a simple app like so:



// 050601 yky Sample Console App to test out csopf.
// Saves a Customer, and loads it again.

/* command to compile it. Make sure the dlls are available too.
mcs Console.cs -r:../../build/csopf.dll -r:../../build/csopf.data.dll
*/

using csopf.Core;
using csopf.Data.SQL;

namespace SampleApp.Console
{

// 050601 yky This is the class which will be persistent.
public class Customer: PDObject
{
static Customer()
{
PDRegistry.RegisterPDObject( typeof(Customer), typeof(SQLDMObject), null );
}

public string CustomerName;
public string Designation;
public string Email;
}

public class RunMe
{
static RunMe()
{
// 050601 yky Initialize SQL persistence.
SQLDB.Init();
}
static public void Main( )
{
System.Console.Write("Hello\n");

// 050601 yky A new Customer, Joe Blow.
Customer vCust = new Customer();
vCust.CustomerName = "Joe";
vCust.Designation = "Blow";
vCust.Email = "joblo@gmail.com";

// 050601 yky Here's the magic... saves to database!
vCust.Save();
System.Console.WriteLine("Wrote Customer " + vCust.ToString() );
// 050601 yky And a new instance to test load it.
Customer vCust2 = new Customer();
// 050601 yky And load it up here...
vCust2.Load( vCust.ID );

System.Console.WriteLine("Read Customer " + vCust2.ToString() );
}
}
}


As you can see, its a very very simple application which saves "Joe"
into persistence and retrieves it out again. The code to do that is basically:
vCust.Save() and vCust2.Load(vCust.ID) ... very intuitive.

Also note that there are no Object to Data mapping files required.
All that meta information is already defined in... guess what? ... your class!

Anyway, Im pleased that this runs ok on Linux, and now I dont know
if I should develop in Gtk# or in Windows.Forms... sigh..

To see how this beast works, the debug.txt file is quite telling:

00001: 0: =================== Starting Debug ==================== 6/1/2005 2:35:52 PM ..Debugger
00002: 0: Created new Static SQLDB ..SQLDB
00003: 15: Creating Registry. .
00004: 0: Initializing SQLDB... .
00005: 10: Registering SampleApp.Console.Customer .
00006: 0: SQL Registering: SampleApp.Console.Customer .
00007: 5: Verifying Table Customer for SampleApp.Console.Customer ..SQLDMObject00008: 10: Registering csopf.Data.SQL.SQLConBase .
00009: 0: SQL Registering: csopf.Data.SQL.SQLConBase .
00011: 10: Registering csopf.Data.SQL.SQLCon .
00012: 0: SQL Registering: csopf.Data.SQL.SQLCon .
00014: 15: Opening the database to: csopftest ..SQLConnectionMySql
00015: -2: Either Database not created or User Login incorrect: Unknown database 'csopftest' ..SQLConnectionMySql
00016: 4: Attempting to create the database: csopftest ..SQLConnectionMySql
00017: 0: Succesfully Created the Database: csopftest ... reconnecting ..SQLConnectionMySql
00018: 4: Waiting for server: 0s ..SQLConnectionMySql
00019: 4: Waiting for server: 1s ..SQLConnectionMySql
00020: 4: Waiting for server: 2s ..SQLConnectionMySql
00021: 4: Waiting for server: 3s ..SQLConnectionMySql
00022: 4: Waiting for server: 4s ..SQLConnectionMySql
00023: 3: Server should be ready. ..SQLConnectionMySql
00024: 15: Opening the database to: csopftest ..SQLConnectionMySql
00025: -2: Customer not found. Attempting to create. Table 'csopftest.Customer' doesn't exist ..SQLDMObject
00026: 15: Attempting to create Table: CREATE TABLE Customer (
ID numeric(18,0) NOT NULL , CustomerName varchar(50) , Designation varchar(50) ,
Email varchar(50) , PRIMARY KEY (ID) ) TYPE = InnoDB ..SQLDMObject

00027: 15: SQL Exec: CREATE TABLE Customer (
ID numeric(18,0) NOT NULL , CustomerName varchar(50) , Designation varchar(50) ,
Email varchar(50) , PRIMARY KEY (ID) ) TYPE = InnoDB ..SQLDMObject

00028: 5: Created new table Customer ..SQLDMObject
00029: 0: Beginning a new Atom ..PDTransaction
00030: 15: Opening the database to: csopftest ..SQLConnectionMySql
00031: 15: Registering IDAllocator to check the table .
00032: 10: Registering csopf.Data.SQL.IDAllocator+IDAllocObj .
00033: 0: SQL Registering: csopf.Data.SQL.IDAllocator+IDAllocObj .
00034: 5: Verifying Table GenID for csopf.Data.SQL.IDAllocator+IDAllocObj ..SQLDMObject
00035: -2: GenID not found. Attempting to create. Table 'csopftest.GenID' doesn't exist ..SQLDMObject
00036: 15: Attempting to create Table: CREATE TABLE GenID (
TableName varchar(50) , LocationCode integer , CountryCode integer ,
CurrentID numeric(18,0) ) TYPE = InnoDB ..SQLDMObject

00037: 15: SQL Exec: CREATE TABLE GenID (
TableName varchar(50) , LocationCode integer , CountryCode integer ,
CurrentID numeric(18,0) ) TYPE = InnoDB ..SQLDMObject

00038: 5: Created new table GenID ..SQLDMObject
00039: 0: SQL Saving Object: 1000000001000 ..SQLDMObject
00040: 15: SQL Exec: INSERT INTO Customer
( Designation, Email, CustomerName, ID ) VALUES ( ?Designation, ?Email, ?CustomerName, ?ID ) ..SQLDMObject
00041: 20: Object Saved. ..SQLDMObject
00042: 0: Applying Atomic Commit. ..PDTransaction

csopf only kicks in when there are objects to be persisted, so this
occurs just when we call vCust.Save().
From 001 - 014 is pretty boring, registering stuff, setting things up.
At 015, the framework detected an error: Database was not created.
So it goes along and creates a database, and waits 5 seconds to reconnect (016-024).
At 024, the framework realises that the Customer Table does not exist,
so it creates one at 026-028.
Once the table is ready, the framework can start saving the object,
so it makes use of transactions (thus InnoDB for MySQL) at 029.
The framework allocates IDs 'manually' and doesnt just use an autoinc.
Thus the use of the IDAllocator and GenID Table (031-038).
Finally, at 039, the Framework saves the data into the database,
and 040 demonstrates that it uses Parameters so injection is not a problem.
Of course we Apply the transaction. 042.

Of course once the database and tables are created,
subsequent runs do not require them to be recreated.

TMNet Horror 1.11 - Redeemed!

What can I say?
Im very happy with the outcome.
Finally after almost 7 months of wrangling, I managed to get my 'money' back. Opened the post today, and found another letter from our beloved TMNet. In it was this months statement, and it just said:



Wooooo hooo! and a sigh of relief!

Not only have they credited me the months of overcharges but I believe they have added the RM44 subscriptions for the months where my service was interrupted. So well done, guys! Im glad you can actually listen to your customers complaints!

However the service levels are really something which need working on, and I hope this blog will illustrate that them big boys cant just get away with this so easy. We have the voice and means to fight back if necessary.

But Im quite happy now, I think it was a good victory, and I guess Im just a sucker for punishment. Ill probably sign up on their RM66 package for the unlimited access... I know, its like paying someone to punish you, but I really dont want to go through the rigmarole of justifying my internet usage WHEN something goes wrong again... Also, there really isnt an alternative in my area!

Oh yes, Im also changing the description of my blog from
"A Simple blog. Currently just to gripe about stuff, namely TMNet, Malaysia's premier ISP."

to something else, as they have to the best of their abilities, redeemed themselves.

The horror ends here...

MyOSS Magazine #2 is out today!


A new month, and Ow Mun Heng has done it again! The dude has managed to rally up numerous contributors to his online Malaysian Open Source Software Magazine (MyOSS Mag). Ive just eyeballed it and it looks good, the articles include Power Management with ACPI, OpenOffic dev, RMS's Free as in Freedom book review and more. And they didnt scrimp on details; all the articles seem quite indepth and well researched.

Go visit the website and pick up the copy here:
MyOSS Magazine Edition 2 - Oh My Gosh! It's Edition 2

But I wish that the mag is actually online, with the pages browsable, instead of it being stuck in a PDF file...

Oh yes, check out the OSS propaganda scattered within the pages, its quite humourous!