add logwriter instance, purify output