-
Notifications
You must be signed in to change notification settings - Fork 83
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Pull request #2756: Releasing Version 65.65.3
Merge in SDK/oci-go-sdk from merge_to_github2024-05-20 to github Squashed commit of the following: commit 14a2364230a89c7f982a23830423465bfedcd1f3 Author: oci-dex-release-bot <[email protected]> Date: Mon May 20 17:01:37 2024 +0000 Releasing version 65 65 3
- Loading branch information
1 parent
0e84ce0
commit 3c73de9
Showing
99 changed files
with
10,281 additions
and
102 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
// Copyright (c) 2016, 2018, 2024, Oracle and/or its affiliates. All rights reserved. | ||
// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. | ||
// Code generated. DO NOT EDIT. | ||
|
||
// Big Data Service API | ||
// | ||
// REST API for Oracle Big Data Service. Use this API to build, deploy, and manage fully elastic Big Data Service clusters. Build on Hadoop, Spark and Data Science distributions, which can be fully integrated with existing enterprise data in Oracle Database and Oracle applications. | ||
// | ||
|
||
package bds | ||
|
||
import ( | ||
"encoding/json" | ||
"fmt" | ||
"github.com/oracle/oci-go-sdk/v65/common" | ||
"strings" | ||
) | ||
|
||
// BackupNodeDetails The information about the nodes to backup. | ||
type BackupNodeDetails struct { | ||
LevelTypeDetails LevelTypeDetails `mandatory:"true" json:"levelTypeDetails"` | ||
|
||
// Incremental backup type includes only the changes since the last backup. Full backup type includes all changes since the volume was created. | ||
BackupType NodeBackupBackupTypeEnum `mandatory:"false" json:"backupType,omitempty"` | ||
} | ||
|
||
func (m BackupNodeDetails) String() string { | ||
return common.PointerString(m) | ||
} | ||
|
||
// ValidateEnumValue returns an error when providing an unsupported enum value | ||
// This function is being called during constructing API request process | ||
// Not recommended for calling this function directly | ||
func (m BackupNodeDetails) ValidateEnumValue() (bool, error) { | ||
errMessage := []string{} | ||
|
||
if _, ok := GetMappingNodeBackupBackupTypeEnum(string(m.BackupType)); !ok && m.BackupType != "" { | ||
errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for BackupType: %s. Supported values are: %s.", m.BackupType, strings.Join(GetNodeBackupBackupTypeEnumStringValues(), ","))) | ||
} | ||
if len(errMessage) > 0 { | ||
return true, fmt.Errorf(strings.Join(errMessage, "\n")) | ||
} | ||
return false, nil | ||
} | ||
|
||
// UnmarshalJSON unmarshals from json | ||
func (m *BackupNodeDetails) UnmarshalJSON(data []byte) (e error) { | ||
model := struct { | ||
BackupType NodeBackupBackupTypeEnum `json:"backupType"` | ||
LevelTypeDetails leveltypedetails `json:"levelTypeDetails"` | ||
}{} | ||
|
||
e = json.Unmarshal(data, &model) | ||
if e != nil { | ||
return | ||
} | ||
var nn interface{} | ||
m.BackupType = model.BackupType | ||
|
||
nn, e = model.LevelTypeDetails.UnmarshalPolymorphicJSON(model.LevelTypeDetails.JsonData) | ||
if e != nil { | ||
return | ||
} | ||
if nn != nil { | ||
m.LevelTypeDetails = nn.(LevelTypeDetails) | ||
} else { | ||
m.LevelTypeDetails = nil | ||
} | ||
|
||
return | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,107 @@ | ||
// Copyright (c) 2016, 2018, 2024, Oracle and/or its affiliates. All rights reserved. | ||
// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. | ||
// Code generated. DO NOT EDIT. | ||
|
||
package bds | ||
|
||
import ( | ||
"fmt" | ||
"github.com/oracle/oci-go-sdk/v65/common" | ||
"net/http" | ||
"strings" | ||
) | ||
|
||
// BackupNodeRequest wrapper for the BackupNode operation | ||
// | ||
// # See also | ||
// | ||
// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/bds/BackupNode.go.html to see an example of how to use BackupNodeRequest. | ||
type BackupNodeRequest struct { | ||
|
||
// The OCID of the cluster. | ||
BdsInstanceId *string `mandatory:"true" contributesTo:"path" name:"bdsInstanceId"` | ||
|
||
// Details for Taking the node's backup | ||
BackupNodeDetails `contributesTo:"body"` | ||
|
||
// The client request ID for tracing. | ||
OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` | ||
|
||
// For optimistic concurrency control. In the PUT or DELETE call | ||
// for a resource, set the `if-match` parameter to the value of the | ||
// etag from a previous GET or POST response for that resource. | ||
// The resource will be updated or deleted only if the etag you | ||
// provide matches the resource's current etag value. | ||
IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` | ||
|
||
// A token that uniquely identifies a request so it can be retried in case of a timeout or | ||
// server error, without risk of executing that same action again. Retry tokens expire after 24 | ||
// hours but can be invalidated before then due to conflicting operations. For example, if a resource | ||
// has been deleted and purged from the system, then a retry of the original creation request | ||
// might be rejected. | ||
OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` | ||
|
||
// Metadata about the request. This information will not be transmitted to the service, but | ||
// represents information that the SDK will consume to drive retry behavior. | ||
RequestMetadata common.RequestMetadata | ||
} | ||
|
||
func (request BackupNodeRequest) String() string { | ||
return common.PointerString(request) | ||
} | ||
|
||
// HTTPRequest implements the OCIRequest interface | ||
func (request BackupNodeRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { | ||
|
||
_, err := request.ValidateEnumValue() | ||
if err != nil { | ||
return http.Request{}, err | ||
} | ||
return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) | ||
} | ||
|
||
// BinaryRequestBody implements the OCIRequest interface | ||
func (request BackupNodeRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { | ||
|
||
return nil, false | ||
|
||
} | ||
|
||
// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. | ||
func (request BackupNodeRequest) RetryPolicy() *common.RetryPolicy { | ||
return request.RequestMetadata.RetryPolicy | ||
} | ||
|
||
// ValidateEnumValue returns an error when providing an unsupported enum value | ||
// This function is being called during constructing API request process | ||
// Not recommended for calling this function directly | ||
func (request BackupNodeRequest) ValidateEnumValue() (bool, error) { | ||
errMessage := []string{} | ||
if len(errMessage) > 0 { | ||
return true, fmt.Errorf(strings.Join(errMessage, "\n")) | ||
} | ||
return false, nil | ||
} | ||
|
||
// BackupNodeResponse wrapper for the BackupNode operation | ||
type BackupNodeResponse struct { | ||
|
||
// The underlying http response | ||
RawResponse *http.Response | ||
|
||
// Unique Oracle-assigned identifier for the request. If you need to contact | ||
// Oracle about a request, provide this request ID. | ||
OpcRequestId *string `presentIn:"header" name:"opc-request-id"` | ||
|
||
// Unique Oracle-assigned identifier for the asynchronous request. You can use this to query status of the asynchronous operation. | ||
OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` | ||
} | ||
|
||
func (response BackupNodeResponse) String() string { | ||
return common.PointerString(response) | ||
} | ||
|
||
// HTTPResponse implements the OCIResponse interface | ||
func (response BackupNodeResponse) HTTPResponse() *http.Response { | ||
return response.RawResponse | ||
} |
Oops, something went wrong.