// This is an automatically generated code sample.
// To make this code sample work in your Oracle Cloud tenancy,
// please replace the values for any parameters whose current values do not fit
// your use case (such as resource IDs, strings containing ‘EXAMPLE’ or ‘unique_id’, and
// boolean, number, and enum parameters with values not fitting your use case).

package main

import (
	"context"
	"fmt"

	"github.com/oracle/oci-go-sdk/v65/common"
	"github.com/oracle/oci-go-sdk/v65/datascience"
	"github.com/oracle/oci-go-sdk/v65/example/helpers"
)

func ExampleUpdateJob() {
	// Create a default authentication provider that uses the DEFAULT
	// profile in the configuration file.
	// Refer to <see href="https://docs.cloud.oracle.com/en-us/iaas/Content/API/Concepts/sdkconfig.htm#SDK_and_CLI_Configuration_File>the public documentation</see> on how to prepare a configuration file.
	client, err := datascience.NewDataScienceClientWithConfigurationProvider(common.DefaultConfigProvider())
	helpers.FatalIfError(err)

	// Create a request and dependent object(s).

	req := datascience.UpdateJobRequest{OpcRequestId: common.String("FSKYXPVF9ERQTIGFMFCC<unique_ID>"),
		UpdateJobDetails: datascience.UpdateJobDetails{DefinedTags: map[string]map[string]interface{}{"EXAMPLE_KEY_rVyn5": map[string]interface{}{"EXAMPLE_KEY_OT0Qd": "EXAMPLE--Value"}},
			Description:  common.String("EXAMPLE-description-Value"),
			DisplayName:  common.String("EXAMPLE-displayName-Value"),
			FreeformTags: map[string]string{"EXAMPLE_KEY_Vh1wx": "EXAMPLE_VALUE_sP46vor3vyMeUL3UOOjY"},
			JobInfrastructureConfigurationDetails: datascience.ManagedEgressStandaloneJobInfrastructureConfigurationDetails{BlockStorageSizeInGBs: common.Int(7503),
				JobShapeConfigDetails: &datascience.JobShapeConfigDetails{Ocpus: common.Float32(51.04828),
					MemoryInGBs: common.Float32(670.0446)},
				ShapeName: common.String("EXAMPLE-shapeName-Value")},
			JobStorageMountConfigurationDetailsList: []datascience.StorageMountConfigurationDetails{datascience.ObjectStorageMountConfigurationDetails{Bucket: common.String("EXAMPLE-bucket-Value"),
				DestinationDirectoryName: common.String("EXAMPLE-destinationDirectoryName-Value"),
				DestinationPath:          common.String("EXAMPLE-destinationPath-Value"),
				Namespace:                common.String("EXAMPLE-namespace-Value"),
				Prefix:                   common.String("EXAMPLE-prefix-Value")}}},
		IfMatch: common.String("EXAMPLE-ifMatch-Value"),
		JobId:   common.String("ocid1.test.oc1..<unique_ID>EXAMPLE-jobId-Value")}

	// Send the request using the service client
	resp, err := client.UpdateJob(context.Background(), req)
	helpers.FatalIfError(err)

	// Retrieve value from the response.
	fmt.Println(resp)
}