Rewrite of the project using 3 tier architecture