December 2011
1 post
Handling sub-domains in ASP.Net MVC
In SaasApp which is framework for mulituser-multitenant SAAS framework for ASP.Net MVC, what I wanted was that when user types the url without a subdomain my app should display the website where user can get details about the product and plans, select a plan and register an account (in this post account refers to say a company that can have multiple users) with selected plan. Once an account is...
October 2011
9 posts
3 tags
Compressing HTML output in ASP.Net / ASP.Net MVC
Most modern browsers have capability to get output from webservers in compressed form. This reduces number of bytes to be transferred and thus making transmission faster. Browsers that support this functionality specify supported compression type as value of “Accept-Encoding” attribute for example “Accept-Encoding: gzip, deflate”. gzip and deflate being two most commonly...
3 tags
MongoDB @ KhojKhabar
(Migrated from old wordpress blog post dated 7/12/2011)
These days NoSQL databases are getting very popular. These databases don’t have a SQL interface for querying data and a lot of times don’t store data as collections of rows and tables. MongoDB is one such database that stores data in form of BSON(a form of JSON) documents and collections. The data in MongoDB can be queried...
2 tags
AppHarbor - Heroku like service for ASP.Net
(Migrated from old wordpress blog post dated 2/17/2011)
I recently came across AppHarbor. It looks like another interesting startup to come out of YCombinator. Its a Heroku like service that builds, runs unit tests and deploys your ASP.Net code for you. It works with Git so to upload the code all you need to do is git push. They provide shared and dedicated databases with option of MS SQL server...
1 tag
jQuery ListCollapse
(Migrated from old wordpress blog post dated 1/9/2011)
This plugin is meant to collapse/expand a list of items that grows beyond certain predefined number of items. It filters and collapses a list when data is bound, added or removed. If number of items are more than specified number n it displays first n items and displays an expand(customizable) link. When a user clicks on this link it displays...
1 tag
Load balancing
(Migrated from old wordpress blog post dated 12/22/2010)
I read an interesting article today about load balancing. Its a must read for anyone looking to scale a website or anyone just simple interested in knowing how these high traffic websites scale on the web server side. This documents explains different ways of doing it like hardware based approach and software based approach. It also...
2 tags
Adding a new volume to EC2 linux instance
(Migrated from old wordpress blog post dated 12/22/2010)
Our postgres EC2 linux instance ran out of disk space so I had to add another volume to the server. Following is what I did -
Login to http://aws.amazon.com and go to EC2 tab.
Go to volumes section and create a new volume.
Enter the size of volume and select the availability zone. I generally skip creating a snapshot unless there is...
1 tag
Moving postgres data folder
(Migrated from old wordpress blog post dated 12/22/2010)
Our postgres server ran out of disk space on our EC2 server so we figured we should move the postgres data folder to a new bigger volume. We created an additional volume mounted to /disk2 and then moved the data folder as follows -
1. Login to shell as root. Stop the Postgres if running
$service postgresql-9.0 stop
2. Copy the data...
2 tags
Setting up replication in Postgres 9.0
(Migrated from old wordpress blog post dated 12/22/2010)
For picksie I had to set up streaming replication in Postgres 9.0. We have a master server which is used for read/write and a hot standby where we want the data to updated using streaming replication. Following is a summary of what I did
1. Install postgres on both master and standby
2. Allow standby server to connect to the master by...
4 tags
Interesting projects at work
(Migrated from old wordpress blog post dated 9/21/2010)
Cloud, iPad and SAAS are some of the most sought after buzz words of software industry right now. Apart from looking after the IT infrastructure, my work involves projects bridge and picksie that together involve all of these.
Bridge is a product targeting enterprise collaboration space, built on my stack of choice for web apps these...