logger rewrite