Use logger instead of printf