Save the whole log to DB if the build is failed.