Added implementation for finite state machine. Added configuration manager