refactored setting properties, and added logging throughout