Archive for September, 2009

Microsoft launched WebsiteSpark which basically is a sort of MSDN licence for developers but targeted only towards web development. What you get is:

  • 3 licenses of Visual Studio 2008 Professional Edition
  • 1 license of Expression Studio 3 (which includes Expression Blend, Sketchflow, and Web)
  • 2 licenses of Expression Web 3
  • 4 processor licenses of Windows Web Server 2008 R2
  • 4 processor licenses of SQL Server 2008 Web Edition
  • DotNetPanel control panel (enabling easy remote/hosted management of your servers)

And all this for free for 3 years. There are some limits still:

  • Your company has to have less than 10 employees
  • Your company must develop web applications for other clients
  • You have to pay 100USD the moment you exit the program (either at the end of the 3 years or sooner)

There are some other things to be known but you can read it here.

Comments No Comments »

Today I tried to fix an automatic build on TFS. The build was failing because of the unit tests. The reason was simple but hard to figure. Let’s imagine the following scenario.
We have an interface IPet and we implement it in two dll’s, HousePets in a class Cat and in GardenPets in class Badger.

namespace HousePets
{
    public class Cat : IPets.IPet
    { ... }
}

namespace GardenPets
{
    public class Dog : IPets.IPet
    { ... }
}

namespace IPets
{
    public interface IPet
    { ... }
}

And extra we have another class which is a loads an assembly and returns an implementation of IPet from one of the 2 dll’s.

public IPets.IPet GetCat()
{
    Assembly catAssembly = Assembly.Load("HousePets.dll");
    return (IPets.IPet)Activator.CreateInstance(catAssembly.GetType("Cat"));
}

Naturally this class is in a project that has no refference to either HousePets nor GardenPets.
If we have a unit test that uses it, in order for it to run, we just add the two projects as references to ensure that HousePets.dll and GardenPets.dll will be present in the bin directory of the unit test project.

While this works on the local machine, when ran in a TFS build environment it will crash. The reason is the static analysis that the TFS is starting. This is not detecting any object of type Cat or Badger and thus the libraries HousePets.dll and GardenPets.dll are not copied in the run directory.

The sollution is simple. Add a class in your unit project:

public class AssemblyInjector
{
    [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Performance"
        "CA1804:RemoveUnusedLocals", MessageId = "c")]
    public AssemblyInjector()
    {
        // make a call to a class of the library we want to be also copied in the
        // test directory
        HousePets.Cat c = new HousePets.Cat();
    }
}

{ Disclaimer: don’t mind the implementation, it’s only there for illustrating the problem and the sollution }

Comments No Comments »

This weekend was all about Braidwood. For those not in the know, Braidwood is the reincarnation of Intel’s Turbo Cache memory. The buzz started with an article from Objective Analysis posted on InforWorld, here.
While the article was let’s say a nice report, it lacked on the technical part as the details on how it functions are very sketchy. This made me wonder what could you gain from using 16Gb of SLC memory on a mainboard. No, it is not intended to act as a harddrive and boot windows from it, but rather to act as cache memory between the harddrive and the system.
I guess we should look at the two operations a harddrive should perform, read and write. When writing the processor has most of the time the data in the memory and it sends it in chunks to the harddrive, this stores it in it’s cache memory and in mean time starts the spinning of the platters to begin the finding of a place to write the bits. Unfortunately this process is a long one, somewhere around 10ms, whereas the processor can get information from the memory under 1ms and thus at some point the processor has to wait for the harddrive to finish the writing and then it sends the next chunk. If we would have some more memory available on the harddrive, the processor could send more chunks and thus not wait until the harddrive finishes. This cache would be the SSD integrated in the mainboard, so we could see some improvements here, especially on many small files that need to be written. Of course for the user the feeling would be that yes, the files were written but the hdd led would still blink for a while, until the cache is emptied.
On the read part … well, there is not much where a greater cache can help, maybe only to store some very often used files such that reads on the harddrive are limited.

Somehow I don’t buy the panic the article starts spreading (OMG the SSD market will crash, there is no need for SSD’s anymore) . Jeez, while I think there are some improvements coming out, the harddrive is still an issue. It can only write so quick and read so quick. The initial begin of an operation will take the same amount of time, no matter the cache dimension or speed.
Also there is another big point to be made. While an SSD costs around 200$, to get the new turbo cache you would have to go through an upgrade to an I5 processor and a compatible motherboard, and that would set you down around 300$ and you still don’t get the same performance improvements.

Just my 2cents …

Comments No Comments »