Improve logging in SQL and content patcher.