Implemented dsl algorithm
setting switch for logging