1. Packages
  2. Oracle Cloud Infrastructure
  3. API Docs
  4. Database
  5. getSchedulingPolicySchedulingWindow
Oracle Cloud Infrastructure v2.29.0 published on Wednesday, Apr 9, 2025 by Pulumi

oci.Database.getSchedulingPolicySchedulingWindow

Explore with Pulumi AI

This data source provides details about a specific Scheduling Policy Scheduling Window resource in Oracle Cloud Infrastructure Database service.

Gets information about the specified Scheduling Window.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as oci from "@pulumi/oci";

const testSchedulingPolicySchedulingWindow = oci.Database.getSchedulingPolicySchedulingWindow({
    schedulingPolicyId: testSchedulingPolicy.id,
    schedulingWindowId: testSchedulingWindow.id,
});
Copy
import pulumi
import pulumi_oci as oci

test_scheduling_policy_scheduling_window = oci.Database.get_scheduling_policy_scheduling_window(scheduling_policy_id=test_scheduling_policy["id"],
    scheduling_window_id=test_scheduling_window["id"])
Copy
package main

import (
	"github.com/pulumi/pulumi-oci/sdk/v2/go/oci/database"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := database.GetSchedulingPolicySchedulingWindow(ctx, &database.GetSchedulingPolicySchedulingWindowArgs{
			SchedulingPolicyId: testSchedulingPolicy.Id,
			SchedulingWindowId: testSchedulingWindow.Id,
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Oci = Pulumi.Oci;

return await Deployment.RunAsync(() => 
{
    var testSchedulingPolicySchedulingWindow = Oci.Database.GetSchedulingPolicySchedulingWindow.Invoke(new()
    {
        SchedulingPolicyId = testSchedulingPolicy.Id,
        SchedulingWindowId = testSchedulingWindow.Id,
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.oci.Database.DatabaseFunctions;
import com.pulumi.oci.Database.inputs.GetSchedulingPolicySchedulingWindowArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        final var testSchedulingPolicySchedulingWindow = DatabaseFunctions.getSchedulingPolicySchedulingWindow(GetSchedulingPolicySchedulingWindowArgs.builder()
            .schedulingPolicyId(testSchedulingPolicy.id())
            .schedulingWindowId(testSchedulingWindow.id())
            .build());

    }
}
Copy
variables:
  testSchedulingPolicySchedulingWindow:
    fn::invoke:
      function: oci:Database:getSchedulingPolicySchedulingWindow
      arguments:
        schedulingPolicyId: ${testSchedulingPolicy.id}
        schedulingWindowId: ${testSchedulingWindow.id}
Copy

Using getSchedulingPolicySchedulingWindow

Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

function getSchedulingPolicySchedulingWindow(args: GetSchedulingPolicySchedulingWindowArgs, opts?: InvokeOptions): Promise<GetSchedulingPolicySchedulingWindowResult>
function getSchedulingPolicySchedulingWindowOutput(args: GetSchedulingPolicySchedulingWindowOutputArgs, opts?: InvokeOptions): Output<GetSchedulingPolicySchedulingWindowResult>
Copy
def get_scheduling_policy_scheduling_window(scheduling_policy_id: Optional[str] = None,
                                            scheduling_window_id: Optional[str] = None,
                                            opts: Optional[InvokeOptions] = None) -> GetSchedulingPolicySchedulingWindowResult
def get_scheduling_policy_scheduling_window_output(scheduling_policy_id: Optional[pulumi.Input[str]] = None,
                                            scheduling_window_id: Optional[pulumi.Input[str]] = None,
                                            opts: Optional[InvokeOptions] = None) -> Output[GetSchedulingPolicySchedulingWindowResult]
Copy
func GetSchedulingPolicySchedulingWindow(ctx *Context, args *GetSchedulingPolicySchedulingWindowArgs, opts ...InvokeOption) (*GetSchedulingPolicySchedulingWindowResult, error)
func GetSchedulingPolicySchedulingWindowOutput(ctx *Context, args *GetSchedulingPolicySchedulingWindowOutputArgs, opts ...InvokeOption) GetSchedulingPolicySchedulingWindowResultOutput
Copy

> Note: This function is named GetSchedulingPolicySchedulingWindow in the Go SDK.

public static class GetSchedulingPolicySchedulingWindow 
{
    public static Task<GetSchedulingPolicySchedulingWindowResult> InvokeAsync(GetSchedulingPolicySchedulingWindowArgs args, InvokeOptions? opts = null)
    public static Output<GetSchedulingPolicySchedulingWindowResult> Invoke(GetSchedulingPolicySchedulingWindowInvokeArgs args, InvokeOptions? opts = null)
}
Copy
public static CompletableFuture<GetSchedulingPolicySchedulingWindowResult> getSchedulingPolicySchedulingWindow(GetSchedulingPolicySchedulingWindowArgs args, InvokeOptions options)
public static Output<GetSchedulingPolicySchedulingWindowResult> getSchedulingPolicySchedulingWindow(GetSchedulingPolicySchedulingWindowArgs args, InvokeOptions options)
Copy
fn::invoke:
  function: oci:Database/getSchedulingPolicySchedulingWindow:getSchedulingPolicySchedulingWindow
  arguments:
    # arguments dictionary
Copy

The following arguments are supported:

SchedulingPolicyId This property is required. string
The Scheduling Policy OCID.
SchedulingWindowId This property is required. string
The Scheduling Window OCID.
SchedulingPolicyId This property is required. string
The Scheduling Policy OCID.
SchedulingWindowId This property is required. string
The Scheduling Window OCID.
schedulingPolicyId This property is required. String
The Scheduling Policy OCID.
schedulingWindowId This property is required. String
The Scheduling Window OCID.
schedulingPolicyId This property is required. string
The Scheduling Policy OCID.
schedulingWindowId This property is required. string
The Scheduling Window OCID.
scheduling_policy_id This property is required. str
The Scheduling Policy OCID.
scheduling_window_id This property is required. str
The Scheduling Window OCID.
schedulingPolicyId This property is required. String
The Scheduling Policy OCID.
schedulingWindowId This property is required. String
The Scheduling Window OCID.

getSchedulingPolicySchedulingWindow Result

The following output properties are available:

CompartmentId string
The OCID of the compartment.
DefinedTags Dictionary<string, string>
Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags.
DisplayName string
The user-friendly name for the Scheduling Window. The name does not need to be unique.
FreeformTags Dictionary<string, string>
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. Example: {"Department": "Finance"}
Id string
The OCID of the Scheduling Window.
LifecycleDetails string
Additional information about the current lifecycle state.
SchedulingPolicyId string
The OCID of the Scheduling Policy.
SchedulingWindowId string
State string
The current state of the Scheduling Window. Valid states are CREATING, ACTIVE, UPDATING, FAILED, DELETING and DELETED.
TimeCreated string
The date and time the Scheduling Window was created.
TimeNextSchedulingWindowStarts string
The date and time of the next upcoming window associated within the schedulingWindow is planned to start.
TimeUpdated string
The last date and time that the Scheduling Window was updated.
WindowPreferences List<GetSchedulingPolicySchedulingWindowWindowPreference>
The Single Scheduling Window details.
CompartmentId string
The OCID of the compartment.
DefinedTags map[string]string
Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags.
DisplayName string
The user-friendly name for the Scheduling Window. The name does not need to be unique.
FreeformTags map[string]string
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. Example: {"Department": "Finance"}
Id string
The OCID of the Scheduling Window.
LifecycleDetails string
Additional information about the current lifecycle state.
SchedulingPolicyId string
The OCID of the Scheduling Policy.
SchedulingWindowId string
State string
The current state of the Scheduling Window. Valid states are CREATING, ACTIVE, UPDATING, FAILED, DELETING and DELETED.
TimeCreated string
The date and time the Scheduling Window was created.
TimeNextSchedulingWindowStarts string
The date and time of the next upcoming window associated within the schedulingWindow is planned to start.
TimeUpdated string
The last date and time that the Scheduling Window was updated.
WindowPreferences []GetSchedulingPolicySchedulingWindowWindowPreference
The Single Scheduling Window details.
compartmentId String
The OCID of the compartment.
definedTags Map<String,String>
Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags.
displayName String
The user-friendly name for the Scheduling Window. The name does not need to be unique.
freeformTags Map<String,String>
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. Example: {"Department": "Finance"}
id String
The OCID of the Scheduling Window.
lifecycleDetails String
Additional information about the current lifecycle state.
schedulingPolicyId String
The OCID of the Scheduling Policy.
schedulingWindowId String
state String
The current state of the Scheduling Window. Valid states are CREATING, ACTIVE, UPDATING, FAILED, DELETING and DELETED.
timeCreated String
The date and time the Scheduling Window was created.
timeNextSchedulingWindowStarts String
The date and time of the next upcoming window associated within the schedulingWindow is planned to start.
timeUpdated String
The last date and time that the Scheduling Window was updated.
windowPreferences List<GetSchedulingPolicySchedulingWindowWindowPreference>
The Single Scheduling Window details.
compartmentId string
The OCID of the compartment.
definedTags {[key: string]: string}
Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags.
displayName string
The user-friendly name for the Scheduling Window. The name does not need to be unique.
freeformTags {[key: string]: string}
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. Example: {"Department": "Finance"}
id string
The OCID of the Scheduling Window.
lifecycleDetails string
Additional information about the current lifecycle state.
schedulingPolicyId string
The OCID of the Scheduling Policy.
schedulingWindowId string
state string
The current state of the Scheduling Window. Valid states are CREATING, ACTIVE, UPDATING, FAILED, DELETING and DELETED.
timeCreated string
The date and time the Scheduling Window was created.
timeNextSchedulingWindowStarts string
The date and time of the next upcoming window associated within the schedulingWindow is planned to start.
timeUpdated string
The last date and time that the Scheduling Window was updated.
windowPreferences GetSchedulingPolicySchedulingWindowWindowPreference[]
The Single Scheduling Window details.
compartment_id str
The OCID of the compartment.
defined_tags Mapping[str, str]
Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags.
display_name str
The user-friendly name for the Scheduling Window. The name does not need to be unique.
freeform_tags Mapping[str, str]
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. Example: {"Department": "Finance"}
id str
The OCID of the Scheduling Window.
lifecycle_details str
Additional information about the current lifecycle state.
scheduling_policy_id str
The OCID of the Scheduling Policy.
scheduling_window_id str
state str
The current state of the Scheduling Window. Valid states are CREATING, ACTIVE, UPDATING, FAILED, DELETING and DELETED.
time_created str
The date and time the Scheduling Window was created.
time_next_scheduling_window_starts str
The date and time of the next upcoming window associated within the schedulingWindow is planned to start.
time_updated str
The last date and time that the Scheduling Window was updated.
window_preferences Sequence[database.GetSchedulingPolicySchedulingWindowWindowPreference]
The Single Scheduling Window details.
compartmentId String
The OCID of the compartment.
definedTags Map<String>
Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags.
displayName String
The user-friendly name for the Scheduling Window. The name does not need to be unique.
freeformTags Map<String>
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. Example: {"Department": "Finance"}
id String
The OCID of the Scheduling Window.
lifecycleDetails String
Additional information about the current lifecycle state.
schedulingPolicyId String
The OCID of the Scheduling Policy.
schedulingWindowId String
state String
The current state of the Scheduling Window. Valid states are CREATING, ACTIVE, UPDATING, FAILED, DELETING and DELETED.
timeCreated String
The date and time the Scheduling Window was created.
timeNextSchedulingWindowStarts String
The date and time of the next upcoming window associated within the schedulingWindow is planned to start.
timeUpdated String
The last date and time that the Scheduling Window was updated.
windowPreferences List<Property Map>
The Single Scheduling Window details.

Supporting Types

GetSchedulingPolicySchedulingWindowWindowPreference

DaysOfWeeks This property is required. List<GetSchedulingPolicySchedulingWindowWindowPreferenceDaysOfWeek>
Days during the week when scheduling window should be performed.
Duration This property is required. int
Duration window allows user to set a duration they plan to allocate for Scheduling window. The duration is in minutes.
IsEnforcedDuration This property is required. bool
Indicates if duration the user plans to allocate for scheduling window is strictly enforced. The default value is FALSE.
Months This property is required. List<GetSchedulingPolicySchedulingWindowWindowPreferenceMonth>
Months during the year when scheduled window should be performed.
StartTime This property is required. string
The scheduling window start time. The value must use the ISO-8601 format "hh:mm".
WeeksOfMonths This property is required. List<int>
Weeks during the month when scheduled window should be performed. Weeks start on the 1st, 8th, 15th, and 22nd days of the month, and have a duration of 7 days. Weeks start and end based on calendar dates, not days of the week. For example, to allow scheduling window during the 2nd week of the month (from the 8th day to the 14th day of the month), use the value 2. Scheduling window cannot be scheduled for the fifth week of months that contain more than 28 days. Note that this parameter works in conjunction with the daysOfWeek and startTime parameters to allow you to specify specific days of the week and hours that scheduled window will be performed.
DaysOfWeeks This property is required. []GetSchedulingPolicySchedulingWindowWindowPreferenceDaysOfWeek
Days during the week when scheduling window should be performed.
Duration This property is required. int
Duration window allows user to set a duration they plan to allocate for Scheduling window. The duration is in minutes.
IsEnforcedDuration This property is required. bool
Indicates if duration the user plans to allocate for scheduling window is strictly enforced. The default value is FALSE.
Months This property is required. []GetSchedulingPolicySchedulingWindowWindowPreferenceMonth
Months during the year when scheduled window should be performed.
StartTime This property is required. string
The scheduling window start time. The value must use the ISO-8601 format "hh:mm".
WeeksOfMonths This property is required. []int
Weeks during the month when scheduled window should be performed. Weeks start on the 1st, 8th, 15th, and 22nd days of the month, and have a duration of 7 days. Weeks start and end based on calendar dates, not days of the week. For example, to allow scheduling window during the 2nd week of the month (from the 8th day to the 14th day of the month), use the value 2. Scheduling window cannot be scheduled for the fifth week of months that contain more than 28 days. Note that this parameter works in conjunction with the daysOfWeek and startTime parameters to allow you to specify specific days of the week and hours that scheduled window will be performed.
daysOfWeeks This property is required. List<GetSchedulingPolicySchedulingWindowWindowPreferenceDaysOfWeek>
Days during the week when scheduling window should be performed.
duration This property is required. Integer
Duration window allows user to set a duration they plan to allocate for Scheduling window. The duration is in minutes.
isEnforcedDuration This property is required. Boolean
Indicates if duration the user plans to allocate for scheduling window is strictly enforced. The default value is FALSE.
months This property is required. List<GetSchedulingPolicySchedulingWindowWindowPreferenceMonth>
Months during the year when scheduled window should be performed.
startTime This property is required. String
The scheduling window start time. The value must use the ISO-8601 format "hh:mm".
weeksOfMonths This property is required. List<Integer>
Weeks during the month when scheduled window should be performed. Weeks start on the 1st, 8th, 15th, and 22nd days of the month, and have a duration of 7 days. Weeks start and end based on calendar dates, not days of the week. For example, to allow scheduling window during the 2nd week of the month (from the 8th day to the 14th day of the month), use the value 2. Scheduling window cannot be scheduled for the fifth week of months that contain more than 28 days. Note that this parameter works in conjunction with the daysOfWeek and startTime parameters to allow you to specify specific days of the week and hours that scheduled window will be performed.
daysOfWeeks This property is required. GetSchedulingPolicySchedulingWindowWindowPreferenceDaysOfWeek[]
Days during the week when scheduling window should be performed.
duration This property is required. number
Duration window allows user to set a duration they plan to allocate for Scheduling window. The duration is in minutes.
isEnforcedDuration This property is required. boolean
Indicates if duration the user plans to allocate for scheduling window is strictly enforced. The default value is FALSE.
months This property is required. GetSchedulingPolicySchedulingWindowWindowPreferenceMonth[]
Months during the year when scheduled window should be performed.
startTime This property is required. string
The scheduling window start time. The value must use the ISO-8601 format "hh:mm".
weeksOfMonths This property is required. number[]
Weeks during the month when scheduled window should be performed. Weeks start on the 1st, 8th, 15th, and 22nd days of the month, and have a duration of 7 days. Weeks start and end based on calendar dates, not days of the week. For example, to allow scheduling window during the 2nd week of the month (from the 8th day to the 14th day of the month), use the value 2. Scheduling window cannot be scheduled for the fifth week of months that contain more than 28 days. Note that this parameter works in conjunction with the daysOfWeek and startTime parameters to allow you to specify specific days of the week and hours that scheduled window will be performed.
days_of_weeks This property is required. Sequence[database.GetSchedulingPolicySchedulingWindowWindowPreferenceDaysOfWeek]
Days during the week when scheduling window should be performed.
duration This property is required. int
Duration window allows user to set a duration they plan to allocate for Scheduling window. The duration is in minutes.
is_enforced_duration This property is required. bool
Indicates if duration the user plans to allocate for scheduling window is strictly enforced. The default value is FALSE.
months This property is required. Sequence[database.GetSchedulingPolicySchedulingWindowWindowPreferenceMonth]
Months during the year when scheduled window should be performed.
start_time This property is required. str
The scheduling window start time. The value must use the ISO-8601 format "hh:mm".
weeks_of_months This property is required. Sequence[int]
Weeks during the month when scheduled window should be performed. Weeks start on the 1st, 8th, 15th, and 22nd days of the month, and have a duration of 7 days. Weeks start and end based on calendar dates, not days of the week. For example, to allow scheduling window during the 2nd week of the month (from the 8th day to the 14th day of the month), use the value 2. Scheduling window cannot be scheduled for the fifth week of months that contain more than 28 days. Note that this parameter works in conjunction with the daysOfWeek and startTime parameters to allow you to specify specific days of the week and hours that scheduled window will be performed.
daysOfWeeks This property is required. List<Property Map>
Days during the week when scheduling window should be performed.
duration This property is required. Number
Duration window allows user to set a duration they plan to allocate for Scheduling window. The duration is in minutes.
isEnforcedDuration This property is required. Boolean
Indicates if duration the user plans to allocate for scheduling window is strictly enforced. The default value is FALSE.
months This property is required. List<Property Map>
Months during the year when scheduled window should be performed.
startTime This property is required. String
The scheduling window start time. The value must use the ISO-8601 format "hh:mm".
weeksOfMonths This property is required. List<Number>
Weeks during the month when scheduled window should be performed. Weeks start on the 1st, 8th, 15th, and 22nd days of the month, and have a duration of 7 days. Weeks start and end based on calendar dates, not days of the week. For example, to allow scheduling window during the 2nd week of the month (from the 8th day to the 14th day of the month), use the value 2. Scheduling window cannot be scheduled for the fifth week of months that contain more than 28 days. Note that this parameter works in conjunction with the daysOfWeek and startTime parameters to allow you to specify specific days of the week and hours that scheduled window will be performed.

GetSchedulingPolicySchedulingWindowWindowPreferenceDaysOfWeek

Name This property is required. string
Name of the month of the year.
Name This property is required. string
Name of the month of the year.
name This property is required. String
Name of the month of the year.
name This property is required. string
Name of the month of the year.
name This property is required. str
Name of the month of the year.
name This property is required. String
Name of the month of the year.

GetSchedulingPolicySchedulingWindowWindowPreferenceMonth

Name This property is required. string
Name of the month of the year.
Name This property is required. string
Name of the month of the year.
name This property is required. String
Name of the month of the year.
name This property is required. string
Name of the month of the year.
name This property is required. str
Name of the month of the year.
name This property is required. String
Name of the month of the year.

Package Details

Repository
oci pulumi/pulumi-oci
License
Apache-2.0
Notes
This Pulumi package is based on the oci Terraform Provider.