Dev @ Work

A day in the life of a developer

My Outsourcing Experience :: Third Day

June 25th, 2009 by

As I told you I am working on an outsourcing project currently with a company based in India to process a lot of content for us.

Today the representative contacted me using Skype (which worked much better than the phone connection). He asked me about the amount of content and told me that the specifications were crystal clear. We did a little chit chat and gave me an indication of the price but he needed the exact amount to provide me the final quote. He said that I would receive it tomorrow.

Skype rocks for this kind of work, it works faster and better than any other form of communication.

Update: I just received a sample based on our specification and it looks really promising, I am going to test it tomorrow to see if it is fully compliant with our specification. 2 days for a sample: OCR + format everything. That is just plain fast.

My Outsourcing Experience :: Second Day

June 24th, 2009 by

Yesterday I wrote about my first day in an outsourcing project for which I am the lead developer. Yesterday I contact a representative of a company in India for a quote for processing a lot of content. We agreed that I would send him the speciffications.

Today I finished translating the specifications and I sent it to him around 16:00 GMT+1. I didn’t expect an answer from him within 18 hours or something because it was 20:00 india time GMT+5 but I received a response within the hour telling me that someone was working on the specifications already. Impressive!

After some research I learned that the company worked in 3 shifts 24/7, so they always have people working. That is quite remarkable compared to businesses in Holland. He promised me that he would send me the quote tomorrow.

Expanding your Website: Make your Visitors Feel Home

June 23rd, 2009 by

Best WebsiteOkay, let’s assume that your website is up and running, you have a steady visitor flow. Google, Yahoo, Ask and Bing know how to find your website and acknowledge you as a valuable source of information. You add new content on a daily basis and your content is valuable to your visitors as you can see in your statistics tool. Your banner positions are filled and revenue is coming in, time to sit back and let the money come to you right?

No, for one single reason: the competition will eventually catch up with you. You have to keep improving continuously to prevent competitors to catch up with you. How? Listen to the demands and wishes of your visitors! You have got to remember that they are in charge of your site, not you! Why? They are not loyal, they don’t love you and they have a choice to go to a new player on your market or an innovating competitor.

How can I learn what my visitors want, you ask yourself?

  • Do not assume anything. Your visitors have a mind of their own.
  • Analyze your statistics; understand what your users are doing on your website. It really pays off to take a course in Google Analytics (or any other statistics tool) or hire a consultant to do this job for you. For example: identify pages which cause visitors to leave (= loose potential income) your website, they might not live up to the expectations that your visitors have of your website.
  • Ask them. Send them a questionnaire about your website in trade of a small gift. Maybe a subscription for a month to your commercial content or a free report. Remember: you have to give in order to receive!
  • Analyze the website of your competitors, understand the strength and weaknesses of their websites and use that knowledge to improve your website. I am not suggesting that you should copy their websites, just learn from their successes and failures. Innovating is more important than providing the same functionality as your competitors.
  • Ask the experts. Your website is most likely build by someone else than yourself, ask those guys for advice. Make sure those guys know what they are doing: their core business is developing and maintaining websites like your own. If you don’t think your supplier is up to that job, hire a consultant from a different company.

I am sure there are a lot more advices to give and I invite you to add your own to this list as well as comment on the current ones. I started this post with the idea of improving the internal search engine of websites but I didn’t have the time to do it yet. Don’t worry though; I will post a follow up about that subject as soon as I can.

In the mean while I hope this advice helps you to improve your website’s visitor count and your revenue!

My Outsourcing Experience :: First Day

June 23rd, 2009 by

Today at my work I started my first project with outsourcing for a client we need to process a lot of content and we decided that it would be best to do that processing in India.

The first step was to contact the business representative of the company in India, I sent him a e-mail about a request for proposal. He phoned me back in about 2 hours, which was pretty impressive considering it was 19:00 in india. The representative spoke English fluently, like I expected. The only thing that was a bit annoying was the phone connection: there was a lot of noise.

Anyway, I briefly spoke to the representative about the project and we agreed that I would send him the specifications and that he would make a quote based on those specifications. Unfortunately I wasn’t able to translate the specifications today, so I will continue tomorrow.

Baking IL With DynamicMethod

May 31st, 2009 by

At the moment I am building a new script engine which is consists of text and expressions embedded in them. Those expressions are basically calls to functions and have any number of arguments. The implementation of those functions is done in C#.

At compile time I don’t know which methods are going to be called so I have to invoke them at runtime. The most obvious way to do that is to use the reflection API of .NET to do a late bound method call. Although, IMHO, this is a perfectly valid solution to this problem it isn’t exactly fast.

System.Reflection.Emit.DynamicMethod is a better alternative for late bound method invocation when it comes to performance. Although it requires you to write Intermediate Language (IL) it is actually quite easy to use.

Read the rest of this entry »

Source Control Software is Essential

May 31st, 2009 by

Last week I encountered a problem with the source control software we use at Liones. The locks on some files became corrupted, which caused that I couldn’t delete those files. This problem (it is solved now btw) made me realize again that a working source control software is the foundation of any software development company.

My preferred source control software is Subversion, simply because it is reliable, fool proof and widely used. There are plenty of others available. It doesn’t really matter which one you pick as long as it is reliable!

Two old articles

April 30th, 2009 by

I just added two of my old articles about the Windows Template Library:

WTL PictureBox

WTL Resourceless Dialog Toolkit

You can also find these articles on the CodeProject and CodeGuru.

Asynchronous Payment Provider Implementation Pattern

March 17th, 2009 by

PaymentToday at Liones I started working on the integration of a payment service provider (PSP) for a web shop implementation. While I was thinking about the architecture I discovered that it is actually very straightforward and that most of the application flow is reusable in different implementations with other PSPs.

Take a look at the UML diagram below; you will notice that there are actually two flows:

  • One synchronous, which guides the user trough the payment screen
  • One asynchronous, which notifies when the payment state changed (payment is confirmed or canceled)

Read the rest of this entry »

Lucene.NET articles

March 14th, 2009 by

I just published the Lucene.NET articles I have been working on. I hope you like them.

Here is an overview of the articles I have written:

  1. Introduction to Lucene
  2. Indexing basics
  3. Search basics
  4. Alternatives ( did you mean …)
  5. Faceted search / Drill down
  6. Class reference

Cheers!

BitArray Calculating Cardinality

February 20th, 2009 by

For my faceted search Lucene.NET implementation I needed to get the cardinality of a BitArray. The cardinality is the number of bits in turned on. I found a VB snippet and I converted that one to C#.

Here is my implementation:

private static readonly byte[] _bitsSetArray256 = new byte[] { 0, 1, 1, 2, 1, 2, 2, 3, 1, 2, 2, 3, 2, 3, 3, 4, 1, 2, 2, 3, 2, 3, 3, 4, 2, 3, 3, 4, 3, 4, 4, 5, 1, 2, 2, 3, 2, 3, 3, 4, 2, 3, 3, 4, 3, 4, 4, 5, 2, 3, 3, 4, 3, 4, 4, 5, 3, 4, 4, 5, 4, 5, 5, 6, 1, 2, 2, 3, 2, 3, 3, 4, 2, 3, 3, 4, 3, 4, 4, 5, 2, 3, 3, 4, 3, 4, 4, 5, 3, 4, 4, 5, 4, 5, 5, 6, 2, 3, 3, 4, 3, 4, 4, 5, 3, 4, 4, 5, 4, 5, 5, 6, 3, 4, 4, 5, 4, 5, 5, 6, 4, 5, 5, 6, 5, 6, 6, 7, 1, 2, 2, 3, 2, 3, 3, 4, 2, 3, 3, 4, 3, 4, 4, 5, 2, 3, 3, 4, 3, 4, 4, 5, 3, 4, 4, 5, 4, 5, 5, 6, 2, 3, 3, 4, 3, 4, 4, 5, 3, 4, 4, 5, 4, 5, 5, 6, 3, 4, 4, 5, 4, 5, 5, 6, 4, 5, 5, 6, 5, 6, 6, 7, 2, 3, 3, 4, 3, 4, 4, 5, 3, 4, 4, 5, 4, 5, 5, 6, 3, 4, 4, 5, 4, 5, 5, 6, 4, 5, 5, 6, 5, 6, 6, 7, 3, 4, 4, 5, 4, 5, 5, 6, 4, 5, 5, 6, 5, 6, 6, 7, 4, 5, 5, 6, 5, 6, 6, 7, 5, 6, 6, 7, 6, 7, 7, 8 };

public static int GetCardinality( BitArray bitArray )
{
var array = (uint[]) bitArray.GetType().GetField( "m_array", System.Reflection.BindingFlags.NonPublic | System.Reflection.BindingFlags.Instance ).GetValue( bitArray );
int count = 0;

for ( int index = 0; index < array.Length; index ++ )
{
count += _bitsSetArray256[ array[ index ] & 0xFF ] + _bitsSetArray256[ ( array[ index ] >> 8 ) & 0xFF ] + _bitsSetArray256[ ( array[ index ] >> 16 ) & 0xFF ] + _bitsSetArray256[ ( array[ index ] >> 24 ) & 0xFF ];
}

return count;
}

The reflection access to the private field of BitArray isn’t exactly fast, but I will optimize it later and post the updated snippet right here.

I hope this implementation is as useful for you as it is for me.