Skip to content

Commit 0995ff0

Browse files
authored
Add out_of_band_deleted attribute to terraformvolume data source and resource (#6320)
1 parent 961eb64 commit 0995ff0

File tree

5 files changed

+16
-1
lines changed

5 files changed

+16
-1
lines changed

ibm/service/power/data_source_ibm_pi_volume.go

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,11 @@ func DataSourceIBMPIVolume() *schema.Resource {
9999
Description: "Mirroring state for replication enabled volume.",
100100
Type: schema.TypeString,
101101
},
102+
Attr_OutOfBandDeleted: {
103+
Computed: true,
104+
Description: "Indicates if the volume does not exist on storage controller.",
105+
Type: schema.TypeBool,
106+
},
102107
Attr_PrimaryRole: {
103108
Computed: true,
104109
Description: "Indicates whether master/auxiliary volume is playing the primary role.",
@@ -197,6 +202,7 @@ func dataSourceIBMPIVolumeRead(ctx context.Context, d *schema.ResourceData, meta
197202
d.Set(Attr_LastUpdateDate, volumedata.LastUpdateDate.String())
198203
d.Set(Attr_MasterVolumeName, volumedata.MasterVolumeName)
199204
d.Set(Attr_MirroringState, volumedata.MirroringState)
205+
d.Set(Attr_OutOfBandDeleted, volumedata.OutOfBandDeleted)
200206
d.Set(Attr_PrimaryRole, volumedata.PrimaryRole)
201207
d.Set(Attr_ReplicationEnabled, volumedata.ReplicationEnabled)
202208
d.Set(Attr_ReplicationType, volumedata.ReplicationType)

ibm/service/power/ibm_pi_constants.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -357,6 +357,7 @@ const (
357357
Attr_Onboardings = "onboardings"
358358
Attr_OperatingSystem = "operating_system"
359359
Attr_OSType = "os_type"
360+
Attr_OutOfBandDeleted = "out_of_band_deleted"
360361
Attr_PeerID = "peer_id"
361362
Attr_PercentComplete = "percent_complete"
362363
Attr_PIInstanceSharedProcessorPool = "shared_processor_pool"

ibm/service/power/resource_ibm_pi_volume.go

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -189,6 +189,11 @@ func ResourceIBMPIVolume() *schema.Resource {
189189
Description: "Mirroring state for replication enabled volume",
190190
Type: schema.TypeString,
191191
},
192+
Attr_OutOfBandDeleted: {
193+
Computed: true,
194+
Description: "Indicates if the volume does not exist on storage controller.",
195+
Type: schema.TypeBool,
196+
},
192197
Attr_PrimaryRole: {
193198
Computed: true,
194199
Description: "Indicates whether 'master'/'auxiliary' volume is playing the primary role.",
@@ -378,12 +383,13 @@ func resourceIBMPIVolumeRead(ctx context.Context, d *schema.ResourceData, meta i
378383
if vol.DeleteOnTermination != nil {
379384
d.Set(Attr_DeleteOnTermination, vol.DeleteOnTermination)
380385
}
386+
d.Set(Arg_ReplicationEnabled, vol.ReplicationEnabled)
381387
d.Set(Attr_GroupID, vol.GroupID)
382388
d.Set(Attr_IOThrottleRate, vol.IoThrottleRate)
383389
d.Set(Attr_MasterVolumeName, vol.MasterVolumeName)
384390
d.Set(Attr_MirroringState, vol.MirroringState)
391+
d.Set(Attr_OutOfBandDeleted, vol.OutOfBandDeleted)
385392
d.Set(Attr_PrimaryRole, vol.PrimaryRole)
386-
d.Set(Arg_ReplicationEnabled, vol.ReplicationEnabled)
387393
d.Set(Attr_ReplicationSites, vol.ReplicationSites)
388394
d.Set(Attr_ReplicationStatus, vol.ReplicationStatus)
389395
d.Set(Attr_ReplicationType, vol.ReplicationType)

website/docs/d/pi_volume.html.markdown

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,7 @@ In addition to all argument reference list, you can access the following attribu
6262
- `last_update_date` - (String) The date when the volume last updated.
6363
- `master_volume_name` - (String) The master volume name.
6464
- `mirroring_state` - (String) Mirroring state for replication enabled volume.
65+
- `out_of_band_deleted` - (Bool) Indicates if the volume does not exist on storage controller.
6566
- `primary_role` - (String) Indicates whether `master`/`auxiliary` volume is playing the primary role.
6667
- `replication_enabled` - (Boolean) Indicates if the volume should be replication enabled or not.
6768
- `replication_sites` - (List) List of replication sites for volume replication.

website/docs/r/pi_volume.html.markdown

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,7 @@ In addition to all argument reference list, you can access the following attribu
8484
- `io_throttle_rate` - (String) Amount of iops assigned to the volume.
8585
- `master_volume_name` - (String) The master volume name.
8686
- `mirroring_state` - (String) Mirroring state for replication enabled volume.
87+
- `out_of_band_deleted` - (Bool) Indicates if the volume does not exist on storage controller.
8788
- `primary_role` - (String) Indicates whether `master`/`auxiliary` volume is playing the primary role.
8889
- `replication_status` - (String) The replication status of the volume.
8990
- `replication_sites` - (List) List of replication sites for volume replication.

0 commit comments

Comments
 (0)