added log writer