public override void ProcessMessage(IEndpoint endpoint, byte[] data) { using (StreamWriter writer = new StreamWriter(_filePath, _append, _encoding)) { writer.Write(Encoding.UTF8.GetString(data)); writer.Close(); MessageSent.Set(); } }