Thursday, February 17, 2011

Uninstalling Powershell to upgrade from windows 2003 server to 2008 server

None of the things mentioned in the google search work. Ultimately, I had to rename the install folder for power shell and delete all the registry keys I could find.

Note that before doing this, I did manage to uninstall whatever I could find related to powershell in the add/ remove programs. Powershell 2.0 comes as part of another microsoft package which I uninstalled first.

Wednesday, February 16, 2011

Lot of updates posted today

We did a lot of updates today including performance fixes, perf counter based monitoring of services, better quality RSS feed where links actually work, and ensuring that reads are tracked properly.

Hopefully, none of these things will need fixing anymore.

Tuesday, February 15, 2011

The real problems with LINQ to SQL

Here is the list of issues with this technology which I have learnt after extensively using it everywhere:

1. It cannot handle multiple threads. Basically it cannot even run 2 database queries at the same time!
2. Above pretty much means you cannot share the context object to use the caching.
3. You have to create multiple context objects everywhere. This is too heavy to use like this.
4. You have to go and set all the columns of the table to "Do not check" and primary key to "Always Check" if you want to use the context object properly.

Just in, I found another problem which made me write this post. If you use LINQ to SQL to interface with a stored procedure, then when you iterate through the result object, the data reader is actually open in the background. This is horrible!. I can't believe MS developers could have written code like this. If you don't know about this behavior and make other database calls before iterating through the result object, the data reader remains open and can cause a deadlock, and the database to get super slow!!!

Wow. Have to use entity framework now. Let us see how good that turns out to be..

Saturday, February 12, 2011

Desktop Site significantly updated

We have published the biggest set of updates ever today. The site will run 50% faster now. Hope everyone likes the changes. There was a small problem with user registration which has also been fixed now.

Sunday, February 6, 2011

A very easy way to deploy across multiple servers

Use dropbox to sync the latest code across all servers. Amazingly, if you do this very often, you will find bugs with Dropbox!!

Multiple Network Adapters in Windows and Network Location Type Public

It is a mess if you try to assign static ip addresses to multiple network adapters in windows. Basically you will see the network location type set to Public and no way to set it to private.

This is because for some weird reason, it sets resets the default gateway to BLANK when you press OK. Just reopen the adapter settings and set the default gateway to the IP address of your router and all will be well again.

Saturday, February 5, 2011

Windows Desktop name resolution from a Mac

I have struggled with this problem using ip addresses for years now. Turns out it is very easy to get name resolution. Just use .local on the LAN.