Adds log_to_s3 instance method to primary module