use loggin priority and replace debug flag property