validateStorageConfig returns the configured bucket and path. It is shared by Export, Status and Cancel because all three need to address the same storage location. The bucket is required for bucket-backed backends. The path defaults to empty if not configured; each backend module provides a dedicat
(backend string)
| 944 | // The path defaults to empty if not configured; each backend module provides |
| 945 | // a dedicated export client that does not fall back to the backup path. |
| 946 | func (s *Scheduler) validateStorageConfig(backend string) (bucket, path string, err error) { |
| 947 | bucket = s.exportConfig.DefaultBucket.Get() |
| 948 | path = s.exportConfig.DefaultPath.Get() |
| 949 | if bucket == "" && requiresBucket(backend) { |
| 950 | return "", "", fmt.Errorf("%w: EXPORT_DEFAULT_BUCKET is required for backend %q", ErrExportValidation, backend) |
| 951 | } |
| 952 | return bucket, path, nil |
| 953 | } |
| 954 | |
| 955 | // resolveClasses determines which classes to export. |
| 956 | // It silently ignores non-existent classes in include/exclude lists to avoid |