Tuesday, November 14, 2006

500 000 x 12 years = the new holocaust

Everyday I wake up, I look over at my wife and count my blessings. Then I get up and walk to my daughters room and watch her sleeping, again counting my blessings.

I go to work to earn money to provide for my family, come home to my beautiful wife and daughter and relax till I start working again later in the evening. It is hard but I do it for the benefit of my family.

While working I end up glancing over at the television to see a report on abortion. Then I almost suffer a massive cardiac arrest when I hear the figures. In South Africa alone this year there have been 500 000 aborts. Count to 500 000. 500 000 lives have been taken, 500 000 children have been killed at the request of the "mothers" carrying them. Mothers, the creatures we look to for comfort, for answers, for protection. Now the definition of mother is someone who decides they can take your life. How secure do you feel now?

Effectively what is being said is that you are not a human being till you are born, you are not alive till you are born. Up until the time you are born you are nothing. Girls who have no idea of how to take care of a child are having sex. Where are the parents?

Say it again, 500 000 children executed at the request of the individual carrying the child. 500 000 lives. Am I the only one who is horrifide at this? I look over at my daughter and can't imagine being without her.

Money is not an excuse. Children don't need rich parents, they don't need fancy houses, they don't need fancy food. All a child needs is their parents. Plain and simple. Stop having premarital sex and if you do have sex before you are married, accept responsibility for your actions. If you fall pregant or are involved with making you partner pregnant step up and accept it. DO NOT make an unborn child suffer (and yes dying is suffering, it isn't painless for the unborn child, have a look. I mean, really visualise) for the sins you have committed. Think how many people there are that CAN NOT have children. Stop being so selfish.

500 000 x 12 = 6 000 000. Think about it. Think about it carefully ...

Friday, October 20, 2006

SOAP and Interoperability : Urban Legends

With the advent of SOAP and the new catch phrase "Interop" I am left wondering just how interoperable Java and C# are.

All documentation on the subject is always one side. If you write a Java web service the documentation assumes you will be connecting with a Java client. The same applies for C#. C# web service assumes C# client.

This week I have been researching Glassfish as a replacement for our failing Tomcat (nothing wrong with Tomcat, it just can't deliver the quality requirements for the project).

Alot of the documentation deals with setting up basic web service RPC style, none deal with the concept of request and response objects. I finally managed to figure out how to do this. I did come across a fantastic article that does deal with C# and Java interop available here.

Once I have completed the research I need to do I will post some examples of things I found relatively hard to find information on.

Tuesday, August 29, 2006

In this corner, weighing in at 2, C#!

What a week we have ahead. After being on course for two weeks doing "Advanced Java" and "XML and Webservices" (oh, offered by the friendly folk at Solms TCD) I am pretty stoked and ready to role with some new ideas.

The initial module of our current development is due for release into user testing at the end of this week. Nerves are on edge a bit but all in all I think it will come off pretty nicely. We obviously have to get through the teething stages but I don't think we will have to much to worry about.

I had an interesting discussion with an indivdual the other day who claimed that C# is better than Java. Naturally after being on the advanced Java course I disagreed. Then looking back on it I think the two are incomparable.

If you think about it logically, Java is platform independant. Yes sure it compiles down to a CRL the same way C# does but the fact that it is platform independant by design means that the two languages have no lowest common denominator. If it was a pure *nix or Windows CRL then fine you can compare them, but it isn't.

This boils down to a conclusion I have raised amongst people many times. Use the right tool for the job. If your target platform is specifically Windows with no chance of moving to another platform, use .NET. If you have to implement your application on a *nix platform only, or it has to be cross platform then use Java.

If you want to develop an enterprise application (which will obviously run on some form of *nix due to instability in Windows (oh yes it is)) then develop Java.

Again, use the right tool for the job. The solution we are deploying is an n-tier SOA solution. The business logic is developed and served via Java frameworks. The thin client is developed in C#. *nix stability with Windows desktops.

So let us all stop comparing apples with bananas and get on with our jobs. The best possible thing any developer can do is learn as many different technologies as possible. This will allow you to provide proper solutions and it makes you more marketable.

Have a happy day now :)

Wednesday, July 19, 2006

Copy protection software

WOW

That is all I can say. I found a file called CmdLineExt02.dll and couldn't delete it so I did some research.

Turns out is is supposed to be part of copy protection software. Now the only game I have installed on my machine (aside from the Novalogic title "Black Hawk Down") is the EA games title "Cricket 2005".

Upon diggin deeper I found that A LOT of my favourite games use this technology and some even make use of software that installs root kits or derivitives of. This is quiet a scary thought as I do all my banking online. Now if some stupid hacker tool hooks up with the root kit there is no ways my anti virus software is going pick it up.

So I have decided to effectively remove all the games from my machine until I can establish which vendor is running what.

To the software vendors I would like to say this. You are inconveniencing the lives of legitimate users with all of this nonsense. ALL software can be cracked and anyone that is using cracked software knows there is a risk attached to it. No my question to you is this. Is it safer to use the legitimate software with all of this nonsense going round? You guys are shooting yourselves in the foot by doing this. Me for one will not buy any more EA titles (which is a disappointment as I was really enjoying the Battlefield 2)

Sunday, July 09, 2006

Zidane shows what is means to use your head

Okay this is off topic I know but it is something that has been bugging me for a LONG time.

The incident between french football player Zidane and some italian player (lost interest in the team after what appeared to be the players humping after scoring a goal) where Zidan head butted the itallian in the chest raised many eyebrows.

If you look at the footage again carefully Zidane was moving away from the player and then turned and head butted him. This can only mean that as the Zidane was walking away the italian must have said something that hit a nerve.

I cannot condone the action but it makes me wonder if the powers that be allow this type of thing to happen by letting the players rile each other up with comments. Some of the comments I have heard (especially in the cricket arena) are absolutely disgusting and I am not suprised that players retaliate.

Now everyone says it is part of the game but I firmly believe that it is not. The only place I can see fitting for this type of behaviour is in some form of fighting sport because once the comments are made you are allowed to beat the snot out of your opponent.

Not to mention the example that this type of behvaiour sets for our children. As a father there is no ways I will condone this type of behaviour from my child/ren. If I had to ever see my child/ren playing with gamesmanship and not sportsmanship I would stop them from playing the sport till they learnt the true values of sport.

For those of us that have forgotten, the true value of sport is not WAR! We have enough governments creating wars. The true meaning of sport is honesty, integrity and fair play. Put money into that equation and now all of a sudden there is under handedness, dishonesty and mind games.

To the governing bodies of sports. Bring back the values of the game. DO NOT allow this degeneration to continue and put the games before the pay cheques. If cleaning up the gaming is going to cost money because sponsors pull out because people prefer watching (what is fast becoming) roman circuses then so be it. Do the right thing, for the sake of our children and the human race as a whole. Think about it. I have no idea how you our the players that employ these tactics sleep at night.

Finally...
Zidane, we bid you farewell from international football. You have had a fantastic career and led your team well. Don't let this incident get you down. As far as I am concerned I would have broken a few noses and probably not lasted more than one game. I hope you had a good laugh in the change rooms at the way the guy went down. Everyone has a breaking point, you found yours tonight.

To the itallian player who got beaten down (LOL). As far as I am concerned you got off lightly. I can think of things a lot worse that I would have done.

Then Buffon (what an unfortunate surname). Did you run off crying to your mother everytime someone did something? How on earth did the red card come it if the ref and linesman did not see the incident?

All in all it was a fantastic game, congrats to italy for winning and a big congrats to Germany for hosting the event extremely well. To the USA, next world cup lads, I am sure you will kick some serious behind. Your dismissal from the world cup to Ghana (vomit) was not because of a lack of skill on your part, it was a brilliant piece of acting that secured that penalty.

To all the players that dive. DON'T complain when the ref doesn't call a legit foul against you. Let me give you a quick lesson. Ref goes home, watches game to view mistakes he might have made. Makes mental notes of players who have dived and is alot more weary of you the next game he refs with you in it. PLAY THE GAME! Give our children proper role models.

To the German team. What an amazing performance. I recon the next world cup is yours!

See you all in South Africa in 2010. (If the planet surives long enough)

Thursday, May 25, 2006

View source and the right click killer

Why oh why would you put something on the internet if you don't want people to view it?

So many times I have seen a really nifty piece of work and wanted to know how the author did it. They, however, had different ideas and implement some contrived method of stopping you from right clicking and viewing the source.

To these authors I have one thing to say, not even Microsoft, the notorious closed source initiative stops people viewing the source on their website.

Think about it. The internet is PUBLIC network. Anything posted on a PUBLIC network is open to, yes you guessed it, the public. Implementing these stupid "anti-right click" mechanisms pisses people off just enough to figure out a way round it.

There are a multitude of ways to get round it and I am going to list them:
A) Save the web page and open it in your favourite text editor locally
B) Certain methods implemented in IE will not work in Firefox, so open the site in that browser rather and then right click and view source.
C) If you have office installed you will have the option to edit in Office, this will reveal the code
D) any site "optimised for Microsoft Internet Explorer" open in firefox or some other browser to circumvent any source protection.
E) Alot of people (including myself but for other reasons) reference external javascripts. look for the tag <script language="JavaScript" src="myjavascript.js"> . Copy the src value and past it int the browser after the domain. This will reveal the javascript file
F) Close the site and never, ever go back. You have to ask yourself what that site is doing and why they would want to prevent you from viewing the source? Something malicious maybe? Javascript security flaws are a dim a dozen.
G)Copy the url and paste it into your favourite download manager and download the processed page for editing locally.

Oh and one other thing for you developers using the .inc file extension. Please, please, please for your own safety map the extention to be processed by the script engine you are running (ASP, PHP etc). If you don't these pages can be viewed in plain text and it is amazing the imformation that can be gleaned from them.

Those of you preventing the right click, STOP! You are wasting your time and effort. You could be doing something more productive and remember, what every you have done, someone else has done better.

Have a happy day :)

Friday, May 19, 2006

C# 505 protocol unsupported and psychotic episodes

There is nothing basic about BASIC authentication when using Tomcat and AXIS to serve web services and a C# windows forms client to consume them.

Many a google search turned up nothing aside from people using a work around to force the client to use HTTP/1.0. I didn't believe this was the best solution as you would have to change it every time you updated the client.

I managed to get Tomcat authenticating users off an OpenLDAP server (very cool). There is also a windows port of the popular LDAP server (search google "windows OpenLDAP"). Then came the mission of getting the client to authenticate against the Tomcat server.

It appears that the problem is related to the Keep Alive settings on the Tomcat server and the way C# deals with it's authentication information. Upon setting the server to not keep connections alive everything started grooving.

so effectively all you do is add the attribute maxKeepAliveRequests="1" to the Tomcat server.conf <Connector> entry and restart apache. Below is an example


<Connector port="8080"
maxHttpHeaderSize="8192"
maxKeepAliveRequests="1"
maxThreads="150"
minSpareThreads="25"
maxSpareThreads="75"
enableLookups="false"
redirectPort="8443"
acceptCount="100"
connectionTimeout="20000"
disableUploadTimeout="true" />




Then in C# create the NetworkCredentials object like so

NetworkCredential cred =
new NetworkCredential("username", "password");

and assign it to the web service object credentials you have created and away you go! I will be posting a tutorial on this soon.

I hope this helps someone, as for more info on the topic refer to the apache bug log here.

On another note a very bright chap pointed out that setting ServicePointManager.Expect100Continue = false; also works (thus allowing the keep alives). His comments can be found here

One day our technologies will talk to each other and be happy. Anyways, I can finally get some sleep tonight and if you have a web service containing sensitive information, please for your own good, secure it. Basic is not the best route to go but it is a start.

Thursday, May 11, 2006

Would you like milk with your serialization?

Man what a mission! I have been sitting for the past four hours trying to figure out how to pass a custom object via SOAP. Everything deals with serailizing the object then calling it using Java. Now my problem lays in the fact that it will be called by C#.

I finally figured out the process I am supposed to follow but for the life of me can't find any decent documentation. Will soldier on though (have, it is my job LOL).

If any of you guys out there have any pointers to some decent documentation I would appreciate it. The platform that is serving the web services is Apache Axis. The client consuming the services is C#.

Thanks in advanced

Friday, May 05, 2006

Procedural is for the army

Okay, don't get me wrong, but procedural code has its place. Inside a little box far away from enterprise solutions. It is great for the quick fix it or the once off or twice off export.

The reason I say this is because developers come and go but the application running your enterprise will be around for a long, long time. Now if you write this solution in procedural code making changes is a NIGHTMARE! If you change one line of code the implications bubble through all 1000 lines of your web page!

Now take Object Orientated design and you have a scalabile, updatable model. It might take longer to design and impliment but at the end of the day are you looking for a quick fix or a long term solution?

Every developer has different ways of developing procedual and object orientated code BUT the object orientated code (if designed properly) has more advantage is the long run. It makes finding procedures easier, updating the procedure shouldn't affect the objects that hook into it (unless it is exposed and used by other classes). What a pleasure!

Anyways, you take the high road and I'll take the low road and have less maintenance to do, which means I get home before you! :P

Enjoy your weekend people.

Thursday, May 04, 2006

mod_rewrite and the jaws of insanity

WOW! what a mission. Who would have thought it would take me almost 12 hours to right a simple rewrite rule! In all fairness I did trash the server config my host so generously set up to run off PHP5 at my request (great bunch of people).

The biggest problem is that I was unable to log the rewrite rule, so eventually I started from scratch and slowly added and subtracted things until I had the rule running. In my rampant search on google I came across some very interesting material. I will post the links tomorrow. It is amazing what is available out there.

The rewrite rule was to convert dynamic urls to appear to be static urls. As soon as I did this I noticed an increase in google activity on the site and the sitemap revealed more pages. So it worked :)

Added two more tutorials to rabiddog.co.za. Both PHP. One dealing with classes and the other dealing with output buffering. The tutorials section is still look a bit bleak but time will fill the holes. This weekend I am hoping to get onto the next section of the site.

Oh and in my travels I came across an article that pretty much sums up the challenge facing good developers and the plague destroying the programming art. http://www.sadeveloper.net/Articles_View.aspx?articleID=235

Wednesday, May 03, 2006

The FAST Lane

Driving home this evening on the M1 I encountered a traffic jam (nothing strange really, happens everyday) and for some arb reason I had a thought. I asked myself "how on earth can the fast lane stop?"

Valid question if you think about it. The fast lane has no off-ramps, no robots (traffic-lights) and no stop streets. To effectively jam up the fast lane it would mean that the lanes end must have stopped.

The fastest lane on the highway has to be the emergency (taxi) lane. These guys rip down the emergency lane and block off ramps because they need to get past them.

Viva metro police, viva traffic police, viva South African law enforcement and excuse me while I vomit.

Up, up and away!

Finally the Rabid Dog labs website has been launched. Although things have started pretty slow I am hopeful that they will pick up. So If you know anyone that does development, that needs a tutorial, a code library or an application, PLEASE ask them to request it at my site. The only way this thing is going to get any bigger is if I get feed back from the community.