[refactoring] Little fixes and adding new features to Executor class.