Refactoring of code and added some files associated with Session handling