From 4bda32704bc81d56ed22c20f96f0b0edd1605041 Mon Sep 17 00:00:00 2001 From: Dnyaneshwari Date: Thu, 14 Aug 2025 10:45:52 +0530 Subject: [PATCH] mgr/dashboard: [RGW] - Target Storage Class in s3 tiering config Fixes: https://tracker.ceph.com/issues/72583 Signed-off-by: Dnyaneshwari Talwekar (cherry picked from commit 0478bf227e77a986217adc7b1b28d1568661fb32) --- .../src/app/ceph/rgw/models/rgw-storage-class.model.ts | 3 +++ .../rgw-storage-class-form.component.ts | 6 ++++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/models/rgw-storage-class.model.ts b/src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/models/rgw-storage-class.model.ts index d23f79678953a..5fd5ffe34b138 100644 --- a/src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/models/rgw-storage-class.model.ts +++ b/src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/models/rgw-storage-class.model.ts @@ -98,6 +98,7 @@ export interface PlacementTarget { glacier_restore_tier_type?: string; restore_storage_class?: string; read_through_restore_days?: number; + target_storage_class?: string; }; storage_class?: string; name?: string; @@ -170,6 +171,8 @@ export const TIER_TYPE_DISPLAY = { GLACIER: 'Cloud S3 Glacier' }; +export const GLACIER_TARGET_STORAGE_CLASS = 'GLACIER'; + export const ALLOW_READ_THROUGH_TEXT = 'Enables fetching objects from remote cloud S3 if not found locally.'; diff --git a/src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-storage-class-form/rgw-storage-class-form.component.ts b/src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-storage-class-form/rgw-storage-class-form.component.ts index 8f66deb5d8fa4..4a1c7589ca568 100644 --- a/src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-storage-class-form/rgw-storage-class-form.component.ts +++ b/src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-storage-class-form/rgw-storage-class-form.component.ts @@ -43,7 +43,8 @@ import { EXPEDITED_TIER_TYPE_TEXT, TextLabels, CLOUD_TIER_REQUIRED_FIELDS, - GLACIER_REQUIRED_FIELDS + GLACIER_REQUIRED_FIELDS, + GLACIER_TARGET_STORAGE_CLASS } from '../models/rgw-storage-class.model'; import { NotificationType } from '~/app/shared/enum/notification-type.enum'; import { NotificationService } from '~/app/shared/services/notification.service'; @@ -500,7 +501,8 @@ export class RgwStorageClassFormComponent extends CdForm implements OnInit { tier_config: { ...tierConfig, glacier_restore_days: rawFormValue.glacier_restore_days, - glacier_restore_tier_type: rawFormValue.glacier_restore_tier_type + glacier_restore_tier_type: rawFormValue.glacier_restore_tier_type, + target_storage_class: GLACIER_TARGET_STORAGE_CLASS } } ] -- 2.39.5