oneoff_patches
Creates, updates, deletes, gets or lists an oneoff_patches resource.
Overview​
| Name | oneoff_patches |
| Type | Resource |
| Id | oci.database.oneoff_patches |
Fields​
The following fields are returned by SELECT queries:
- get
- list
One-off patch information was retrieved.
| Name | Datatype | Description |
|---|---|---|
id | string | The [OCID](/Content/General/Concepts/identifiers.htm) of the one-off patch. |
compartmentId | string | The [OCID](/Content/General/Concepts/identifiers.htm) of the compartment. |
dbVersion | string | A valid Oracle Database version. For a list of supported versions, use the ListDbVersions operation. This cannot be updated in parallel with any of the following: licenseModel, dbEdition, cpuCoreCount, computeCount, computeModel, adminPassword, whitelistedIps, isMTLSConnectionRequired, openMode, permissionLevel, dbWorkload, privateEndpointLabel, nsgIds, isRefreshable, dbName, scheduledOperations, dbToolsDetails, isLocalDataGuardEnabled, or isFreeTier. |
definedTags | object | Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see [Resource Tags](/Content/General/Concepts/resourcetags.htm). |
displayName | string | One-off patch name. |
freeformTags | object | Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see [Resource Tags](/Content/General/Concepts/resourcetags.htm). Example: {"Department": "Finance"} |
lifecycleDetails | string | Detailed message for the lifecycle state. |
lifecycleState | string | The current state of the one-off patch. (CREATING, AVAILABLE, UPDATING, INACTIVE, FAILED, EXPIRED, DELETING, DELETED, TERMINATING, TERMINATED) |
oneOffPatches | array | List of one-off patches for Database Homes. |
releaseUpdate | string | The PSU or PBP or Release Updates. To get a list of supported versions, use the [ListDbVersions](#/en/database/latest/DbVersionSummary/ListDbVersions) operation. |
sha256Sum | string | SHA-256 checksum of the one-off patch. |
sizeInKBs | number (float) | The size of one-off patch in kilobytes. |
systemTags | object | System tags for this resource. Each key is predefined and scoped to a namespace. For more information, see [Resource Tags](/Content/General/Concepts/resourcetags.htm). |
timeCreated | string (date-time) | The date and time one-off patch was created. |
timeOfExpiration | string (date-time) | The date and time until which the one-off patch will be available for download. |
timeUpdated | string (date-time) | The date and time one-off patch was updated. |
An Oracle one-off patch for a specified database version.<br /><br />To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, talk to an administrator. If you're an administrator who needs to write policies to give users access, see [Getting Started with Policies](/Content/Identity/Concepts/policygetstarted.htm).<br /><br />Warning: Oracle recommends that you avoid using any confidential information when you supply string values using the API.<br />
| Name | Datatype | Description |
|---|---|---|
id | string | The [OCID](/Content/General/Concepts/identifiers.htm) of the one-off patch. |
compartmentId | string | The [OCID](/Content/General/Concepts/identifiers.htm) of the compartment. |
dbVersion | string | A valid Oracle Database version. For a list of supported versions, use the ListDbVersions operation. This cannot be updated in parallel with any of the following: licenseModel, dbEdition, cpuCoreCount, computeCount, computeModel, adminPassword, whitelistedIps, isMTLSConnectionRequired, openMode, permissionLevel, dbWorkload, privateEndpointLabel, nsgIds, isRefreshable, dbName, scheduledOperations, dbToolsDetails, isLocalDataGuardEnabled, or isFreeTier. |
definedTags | object | Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see [Resource Tags](/Content/General/Concepts/resourcetags.htm). |
displayName | string | One-off patch name. |
freeformTags | object | Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see [Resource Tags](/Content/General/Concepts/resourcetags.htm). Example: {"Department": "Finance"} |
lifecycleDetails | string | Detailed message for the lifecycle state. |
lifecycleState | string | The current state of the one-off patch. (CREATING, AVAILABLE, UPDATING, INACTIVE, FAILED, EXPIRED, DELETING, DELETED, TERMINATING, TERMINATED) |
oneOffPatches | array | List of one-off patches for Database Homes. |
releaseUpdate | string | The PSU or PBP or Release Updates. To get a list of supported versions, use the [ListDbVersions](#/en/database/latest/DbVersionSummary/ListDbVersions) operation. |
sha256Sum | string | SHA-256 checksum of the one-off patch. |
sizeInKBs | number (float) | The size of one-off patch in kilobytes. |
systemTags | object | System tags for this resource. Each key is predefined and scoped to a namespace. For more information, see [Resource Tags](/Content/General/Concepts/resourcetags.htm). |
timeCreated | string (date-time) | The date and time one-off patch was created. |
timeOfExpiration | string (date-time) | The date and time until which the one-off patch will be available for download. |
timeUpdated | string (date-time) | The date and time one-off patch was updated. |
Methods​
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | oneoffPatchId, region | opc-request-id | Gets information about the specified one-off patch.<br /> |
list | select | compartmentId, region | limit, page, sortBy, sortOrder, lifecycleState, displayName, opc-request-id | Lists one-off patches in the specified compartment.<br /> |
create | insert | region, compartmentId, displayName, dbVersion, releaseUpdate | opc-retry-token, opc-request-id | Creates one-off patch for specified database version to download.<br /> |
update | update | oneoffPatchId, region | if-match, opc-request-id | Updates the properties of the specified one-off patch.<br /> |
delete | delete | oneoffPatchId, region | opc-request-id, if-match | Deletes a one-off patch.<br /> |
change_compartment | exec | oneoffPatchId, region, compartmentId | opc-retry-token, opc-request-id, if-match | Move the one-off patch to the specified compartment.<br /> |
download_oneoff_patch | exec | oneoffPatchId, region | opc-retry-token, opc-request-id, if-match | Download one-off patch.<br /> |
Parameters​
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
compartmentId | string | The compartment [OCID](/Content/General/Concepts/identifiers.htm). |
oneoffPatchId | string | The one-off patch [OCID](/Content/General/Concepts/identifiers.htm). |
region | string | OCI region identifier (e.g. us-ashburn-1, ap-sydney-1); resolves from OCI_REGION when not supplied in the query. (default: us-ashburn-1, x-stackQL-envVar: OCI_REGION) |
displayName | string | A filter to return only resources that match the entire display name given. The match is not case sensitive. |
if-match | string | 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. |
lifecycleState | string | A filter to return only resources that match the given lifecycle state exactly |
limit | integer | The maximum number of items to return per page. |
opc-request-id | string | Unique identifier for the request. |
opc-retry-token | string | 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 may be rejected). |
page | string | The pagination token to continue listing from. |
sortBy | string | The field to sort by. You can provide one sort order (sortOrder). Default order for TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME sort order is case sensitive. |
sortOrder | string | The sort order to use, either ascending (ASC) or descending (DESC). |
SELECT examples​
- get
- list
Gets information about the specified one-off patch.<br />
SELECT
id,
compartmentId,
dbVersion,
definedTags,
displayName,
freeformTags,
lifecycleDetails,
lifecycleState,
oneOffPatches,
releaseUpdate,
sha256Sum,
sizeInKBs,
systemTags,
timeCreated,
timeOfExpiration,
timeUpdated
FROM oci.database.oneoff_patches
WHERE oneoffPatchId = '{{ oneoffPatchId }}' -- required
AND region = '{{ region }}' -- required
AND opc-request-id = '{{ opc-request-id }}'
;
Lists one-off patches in the specified compartment.<br />
SELECT
id,
compartmentId,
dbVersion,
definedTags,
displayName,
freeformTags,
lifecycleDetails,
lifecycleState,
oneOffPatches,
releaseUpdate,
sha256Sum,
sizeInKBs,
systemTags,
timeCreated,
timeOfExpiration,
timeUpdated
FROM oci.database.oneoff_patches
WHERE compartmentId = '{{ compartmentId }}' -- required
AND region = '{{ region }}' -- required
AND limit = '{{ limit }}'
AND page = '{{ page }}'
AND sortBy = '{{ sortBy }}'
AND sortOrder = '{{ sortOrder }}'
AND lifecycleState = '{{ lifecycleState }}'
AND displayName = '{{ displayName }}'
AND opc-request-id = '{{ opc-request-id }}'
;
INSERT examples​
- create
- Manifest
Creates one-off patch for specified database version to download.<br />
INSERT INTO oci.database.oneoff_patches (
compartmentId,
dbVersion,
definedTags,
displayName,
freeformTags,
oneOffPatches,
releaseUpdate,
region,
opc-retry-token,
opc-request-id
)
SELECT
'{{ compartmentId }}' /* required */,
'{{ dbVersion }}' /* required */,
'{{ definedTags }}',
'{{ displayName }}' /* required */,
'{{ freeformTags }}',
'{{ oneOffPatches }}',
'{{ releaseUpdate }}' /* required */,
'{{ region }}',
'{{ opc-retry-token }}',
'{{ opc-request-id }}'
RETURNING
id,
compartmentId,
dbVersion,
definedTags,
displayName,
freeformTags,
lifecycleDetails,
lifecycleState,
oneOffPatches,
releaseUpdate,
sha256Sum,
sizeInKBs,
systemTags,
timeCreated,
timeOfExpiration,
timeUpdated
;
# Description fields are for documentation purposes
- name: oneoff_patches
props:
- name: region
value: "{{ region }}"
description: Required parameter for the oneoff_patches resource.
- name: compartmentId
value: "{{ compartmentId }}"
description: |
The [OCID](/Content/General/Concepts/identifiers.htm) of the compartment.
- name: dbVersion
value: "{{ dbVersion }}"
description: |
A valid Oracle Database version. For a list of supported versions, use the ListDbVersions operation.
This cannot be updated in parallel with any of the following: licenseModel, dbEdition, cpuCoreCount, computeCount, computeModel, adminPassword, whitelistedIps, isMTLSConnectionRequired, openMode, permissionLevel, dbWorkload, privateEndpointLabel, nsgIds, isRefreshable, dbName, scheduledOperations, dbToolsDetails, isLocalDataGuardEnabled, or isFreeTier.
- name: definedTags
value: "{{ definedTags }}"
description: |
Defined tags for this resource. Each key is predefined and scoped to a namespace.
For more information, see [Resource Tags](/Content/General/Concepts/resourcetags.htm).
- name: displayName
value: "{{ displayName }}"
description: |
One-off patch name.
- name: freeformTags
value: "{{ freeformTags }}"
description: |
Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace.
For more information, see [Resource Tags](/Content/General/Concepts/resourcetags.htm).
Example: `{"Department": "Finance"}`
- name: oneOffPatches
value:
- "{{ oneOffPatches }}"
description: |
List of one-off patches for Database Homes.
- name: releaseUpdate
value: "{{ releaseUpdate }}"
description: |
The PSU or PBP or Release Updates. To get a list of supported versions, use the [ListDbVersions](#/en/database/latest/DbVersionSummary/ListDbVersions) operation.
- name: opc-retry-token
value: "{{ opc-retry-token }}"
description: 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 may be rejected).
description: 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 may be rejected).
- name: opc-request-id
value: "{{ opc-request-id }}"
description: Unique identifier for the request.
description: Unique identifier for the request.
UPDATE examples​
- update
Updates the properties of the specified one-off patch.<br />
UPDATE oci.database.oneoff_patches
SET
definedTags = '{{ definedTags }}',
freeformTags = '{{ freeformTags }}'
WHERE
oneoffPatchId = '{{ oneoffPatchId }}' --required
AND region = '{{ region }}' --required
AND if-match = '{{ if-match}}'
AND opc-request-id = '{{ opc-request-id}}'
RETURNING
id,
compartmentId,
dbVersion,
definedTags,
displayName,
freeformTags,
lifecycleDetails,
lifecycleState,
oneOffPatches,
releaseUpdate,
sha256Sum,
sizeInKBs,
systemTags,
timeCreated,
timeOfExpiration,
timeUpdated;
DELETE examples​
- delete
Deletes a one-off patch.<br />
DELETE FROM oci.database.oneoff_patches
WHERE oneoffPatchId = '{{ oneoffPatchId }}' --required
AND region = '{{ region }}' --required
AND opc-request-id = '{{ opc-request-id }}'
AND if-match = '{{ if-match }}'
;
Lifecycle Methods​
- change_compartment
- download_oneoff_patch
Move the one-off patch to the specified compartment.<br />
EXEC oci.database.oneoff_patches.change_compartment
@oneoffPatchId='{{ oneoffPatchId }}' --required,
@region='{{ region }}' --required,
@opc-retry-token='{{ opc-retry-token }}',
@opc-request-id='{{ opc-request-id }}',
@if-match='{{ if-match }}'
@@json=
'{
"compartmentId": "{{ compartmentId }}"
}'
;
Download one-off patch.<br />
EXEC oci.database.oneoff_patches.download_oneoff_patch
@oneoffPatchId='{{ oneoffPatchId }}' --required,
@region='{{ region }}' --required,
@opc-retry-token='{{ opc-retry-token }}',
@opc-request-id='{{ opc-request-id }}',
@if-match='{{ if-match }}'
;