fixed blocking condition
config cleanup
restructuring listeners