Skip to content

Commit 7eccd40

Browse files
committed
Show Created At column for volume backups
The ``volume backup list`` command does not show the created_at column for backups which doesn't really help the end-user since a critical part of a backup is knowing when it was taken, and fast if there is a rush doing recovery by restoring a volume from a backup. Change-Id: I8d8a7f36c468c9faa2c2c47bfa9ba9e1ca5b9858
1 parent 5e5b89f commit 7eccd40

3 files changed

Lines changed: 9 additions & 0 deletions

File tree

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
---
2+
features:
3+
- |
4+
Listing volume backups now shows the created_at column.

openstackclient/tests/unit/volume/v2/test_volume_backup.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -359,6 +359,7 @@ class TestBackupList(TestBackup):
359359
'Status',
360360
'Size',
361361
'Incremental',
362+
'Created At',
362363
)
363364
columns_long = columns + (
364365
'Availability Zone',
@@ -376,6 +377,7 @@ class TestBackupList(TestBackup):
376377
b.status,
377378
b.size,
378379
b.is_incremental,
380+
b.created_at,
379381
)
380382
)
381383
data_long = []
@@ -388,6 +390,7 @@ class TestBackupList(TestBackup):
388390
b.status,
389391
b.size,
390392
b.is_incremental,
393+
b.created_at,
391394
b.availability_zone,
392395
volume_backup.VolumeIdColumn(b.volume_id),
393396
b.container,

openstackclient/volume/v2/volume_backup.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -305,6 +305,7 @@ def take_action(self, parsed_args):
305305
'status',
306306
'size',
307307
'is_incremental',
308+
'created_at',
308309
)
309310
column_headers = (
310311
'ID',
@@ -313,6 +314,7 @@ def take_action(self, parsed_args):
313314
'Status',
314315
'Size',
315316
'Incremental',
317+
'Created At',
316318
)
317319
if parsed_args.long:
318320
columns += ('availability_zone', 'volume_id', 'container')

0 commit comments

Comments
 (0)