Class: Google::Apis::AlloydbV1alpha::WeeklySchedule

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/alloydb_v1alpha/classes.rb,
lib/google/apis/alloydb_v1alpha/representations.rb,
lib/google/apis/alloydb_v1alpha/representations.rb

Overview

A weekly schedule starts a backup at prescribed start times within a day, for the specified days of the week. The weekly schedule message is flexible and can be used to create many types of schedules. For example, to have a daily backup that starts at 22:00, configure the start_times field to have one element "22:00" and the days_of_week field to have all seven days of the week.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ WeeklySchedule

Returns a new instance of WeeklySchedule.



3557
3558
3559
# File 'lib/google/apis/alloydb_v1alpha/classes.rb', line 3557

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#days_of_weekArray<String>

The days of the week to perform a backup. If this field is left empty, the default of every day of the week is used. Corresponds to the JSON property daysOfWeek

Returns:

  • (Array<String>)


3548
3549
3550
# File 'lib/google/apis/alloydb_v1alpha/classes.rb', line 3548

def days_of_week
  @days_of_week
end

#start_timesArray<Google::Apis::AlloydbV1alpha::GoogleTypeTimeOfDay>

The times during the day to start a backup. The start times are assumed to be in UTC and to be an exact hour (e.g., 04:00:00). If no start times are provided, a single fixed start time is chosen arbitrarily. Corresponds to the JSON property startTimes



3555
3556
3557
# File 'lib/google/apis/alloydb_v1alpha/classes.rb', line 3555

def start_times
  @start_times
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



3562
3563
3564
3565
# File 'lib/google/apis/alloydb_v1alpha/classes.rb', line 3562

def update!(**args)
  @days_of_week = args[:days_of_week] if args.key?(:days_of_week)
  @start_times = args[:start_times] if args.key?(:start_times)
end