33
44/*
55 * IBM OpenAPI Terraform Generator Version: 3.107.1-41b0fbd0-20250825-080732
6- */
6+ */
77
88package vpc
99
@@ -19,49 +19,49 @@ import (
1919 "github.com/IBM-Cloud/terraform-provider-ibm/ibm/flex"
2020 "github.com/IBM-Cloud/terraform-provider-ibm/ibm/validate"
2121 "github.com/IBM/go-sdk-core/v5/core"
22- "github.ibm. com/ibmcloud /vpc-go-sdk/vpcv1"
22+ "github.com/IBM /vpc-go-sdk/vpcv1"
2323)
2424
2525func ResourceIBMIsVolumeJob () * schema.Resource {
2626 return & schema.Resource {
27- CreateContext : resourceIBMIsVolumeJobCreate ,
28- ReadContext : resourceIBMIsVolumeJobRead ,
29- UpdateContext : resourceIBMIsVolumeJobUpdate ,
30- DeleteContext : resourceIBMIsVolumeJobDelete ,
31- Importer : & schema.ResourceImporter {},
27+ CreateContext : resourceIBMIsVolumeJobCreate ,
28+ ReadContext : resourceIBMIsVolumeJobRead ,
29+ UpdateContext : resourceIBMIsVolumeJobUpdate ,
30+ DeleteContext : resourceIBMIsVolumeJobDelete ,
31+ Importer : & schema.ResourceImporter {},
3232
3333 Schema : map [string ]* schema.Schema {
3434 "volume_id" : & schema.Schema {
35- Type : schema .TypeString ,
36- Required : true ,
37- ForceNew : true ,
35+ Type : schema .TypeString ,
36+ Required : true ,
37+ ForceNew : true ,
3838 ValidateFunc : validate .InvokeValidator ("ibm_is_volume_job" , "volume_id" ),
39- Description : "The volume identifier." ,
39+ Description : "The volume identifier." ,
4040 },
4141 "start" : & schema.Schema {
42- Type : schema .TypeString ,
43- Optional : true ,
42+ Type : schema .TypeString ,
43+ Optional : true ,
4444 ValidateFunc : validate .InvokeValidator ("ibm_is_volume_job" , "start" ),
45- Description : "A server-provided token determining what resource to start the page on." ,
45+ Description : "A server-provided token determining what resource to start the page on." ,
4646 },
4747 "limit" : & schema.Schema {
48- Type : schema .TypeInt ,
49- Optional : true ,
50- Default : 50 ,
48+ Type : schema .TypeInt ,
49+ Optional : true ,
50+ Default : 50 ,
5151 ValidateFunc : validate .InvokeValidator ("ibm_is_volume_job" , "limit" ),
52- Description : "The number of resources to return on a page." ,
52+ Description : "The number of resources to return on a page." ,
5353 },
5454 "job_type" : & schema.Schema {
55- Type : schema .TypeString ,
56- Required : true ,
55+ Type : schema .TypeString ,
56+ Required : true ,
5757 ValidateFunc : validate .InvokeValidator ("ibm_is_volume_job" , "job_type" ),
58- Description : "The type of volume job.The enumerated values for this property may[expand](https://cloud.ibm.com/apidocs/vpc#property-value-expansion) in the future." ,
58+ Description : "The type of volume job.The enumerated values for this property may[expand](https://cloud.ibm.com/apidocs/vpc#property-value-expansion) in the future." ,
5959 },
6060 "name" : & schema.Schema {
61- Type : schema .TypeString ,
62- Optional : true ,
61+ Type : schema .TypeString ,
62+ Optional : true ,
6363 ValidateFunc : validate .InvokeValidator ("ibm_is_volume_job" , "name" ),
64- Description : "The name for this volume job. The name must not be used by another volume job for this volume." ,
64+ Description : "The name for this volume job. The name must not be used by another volume job for this volume." ,
6565 },
6666 "parameters" : & schema.Schema {
6767 Type : schema .TypeList ,
@@ -233,7 +233,7 @@ func ResourceIBMIsVolumeJobValidator() *validate.ResourceValidator {
233233}
234234
235235func resourceIBMIsVolumeJobCreate (context context.Context , d * schema.ResourceData , meta interface {}) diag.Diagnostics {
236- vpcClient , err := meta .(conns.ClientSession ).VpcV1 ()
236+ vpcClient , err := meta .(conns.ClientSession ).VpcV1API ()
237237 if err != nil {
238238 tfErr := flex .DiscriminatedTerraformErrorf (err , err .Error (), "ibm_is_volume_job" , "create" , "initialize-client" )
239239 log .Printf ("[DEBUG]\n %s" , tfErr .GetDebugMessage ())
@@ -277,7 +277,7 @@ func resourceIBMIsVolumeJobCreate(context context.Context, d *schema.ResourceDat
277277}
278278
279279func resourceIBMIsVolumeJobRead (context context.Context , d * schema.ResourceData , meta interface {}) diag.Diagnostics {
280- vpcClient , err := meta .(conns.ClientSession ).VpcV1 ()
280+ vpcClient , err := meta .(conns.ClientSession ).VpcV1API ()
281281 if err != nil {
282282 tfErr := flex .DiscriminatedTerraformErrorf (err , err .Error (), "ibm_is_volume_job" , "read" , "initialize-client" )
283283 log .Printf ("[DEBUG]\n %s" , tfErr .GetDebugMessage ())
@@ -385,7 +385,7 @@ func resourceIBMIsVolumeJobRead(context context.Context, d *schema.ResourceData,
385385}
386386
387387func resourceIBMIsVolumeJobUpdate (context context.Context , d * schema.ResourceData , meta interface {}) diag.Diagnostics {
388- vpcClient , err := meta .(conns.ClientSession ).VpcV1 ()
388+ vpcClient , err := meta .(conns.ClientSession ).VpcV1API ()
389389 if err != nil {
390390 tfErr := flex .DiscriminatedTerraformErrorf (err , err .Error (), "ibm_is_volume_job" , "update" , "initialize-client" )
391391 log .Printf ("[DEBUG]\n %s" , tfErr .GetDebugMessage ())
@@ -406,7 +406,7 @@ func resourceIBMIsVolumeJobUpdate(context context.Context, d *schema.ResourceDat
406406
407407 patchVals := & vpcv1.VolumeJobPatch {}
408408 if d .HasChange ("volume_id" ) {
409- errMsg := fmt .Sprintf ("Cannot update resource property \" %s\" with the ForceNew annotation." +
409+ errMsg := fmt .Sprintf ("Cannot update resource property \" %s\" with the ForceNew annotation." +
410410 " The resource must be re-created to update this property." , "volume_id" )
411411 return flex .DiscriminatedTerraformErrorf (nil , errMsg , "ibm_is_volume_job" , "update" , "volume_id-forces-new" ).GetDiag ()
412412 }
@@ -434,7 +434,7 @@ func resourceIBMIsVolumeJobUpdate(context context.Context, d *schema.ResourceDat
434434}
435435
436436func resourceIBMIsVolumeJobDelete (context context.Context , d * schema.ResourceData , meta interface {}) diag.Diagnostics {
437- vpcClient , err := meta .(conns.ClientSession ).VpcV1 ()
437+ vpcClient , err := meta .(conns.ClientSession ).VpcV1API ()
438438 if err != nil {
439439 tfErr := flex .DiscriminatedTerraformErrorf (err , err .Error (), "ibm_is_volume_job" , "delete" , "initialize-client" )
440440 log .Printf ("[DEBUG]\n %s" , tfErr .GetDebugMessage ())
0 commit comments