| 3522 | } // namespace |
| 3523 | |
| 3524 | Status InitializeS3(const S3GlobalOptions& options) { |
| 3525 | ARROW_ASSIGN_OR_RAISE(bool successfully_initialized, |
| 3526 | EnsureAwsInstanceInitialized(options)); |
| 3527 | if (!successfully_initialized) { |
| 3528 | return Status::Invalid( |
| 3529 | "S3 was already initialized. It is safe to use but the options passed in this " |
| 3530 | "call have been ignored."); |
| 3531 | } |
| 3532 | return Status::OK(); |
| 3533 | } |
| 3534 | |
| 3535 | Status EnsureS3Initialized() { |
| 3536 | return EnsureAwsInstanceInitialized(S3GlobalOptions::Defaults()).status(); |