aws-cdk-lib 2.97.0__py3-none-any.whl → 2.97.1__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of aws-cdk-lib might be problematic. Click here for more details.

aws_cdk/__init__.py CHANGED
@@ -9802,167 +9802,6 @@ class CopyOptions:
9802
9802
  )
9803
9803
 
9804
9804
 
9805
- @jsii.data_type(
9806
- jsii_type="aws-cdk-lib.CronOptions",
9807
- jsii_struct_bases=[],
9808
- name_mapping={
9809
- "day": "day",
9810
- "hour": "hour",
9811
- "minute": "minute",
9812
- "month": "month",
9813
- "time_zone": "timeZone",
9814
- "week_day": "weekDay",
9815
- "year": "year",
9816
- },
9817
- )
9818
- class CronOptions:
9819
- def __init__(
9820
- self,
9821
- *,
9822
- day: typing.Optional[builtins.str] = None,
9823
- hour: typing.Optional[builtins.str] = None,
9824
- minute: typing.Optional[builtins.str] = None,
9825
- month: typing.Optional[builtins.str] = None,
9826
- time_zone: typing.Optional["TimeZone"] = None,
9827
- week_day: typing.Optional[builtins.str] = None,
9828
- year: typing.Optional[builtins.str] = None,
9829
- ) -> None:
9830
- '''Options to configure a cron expression.
9831
-
9832
- All fields are strings so you can use complex expressions. Absence of
9833
- a field implies '*' or '?', whichever one is appropriate.
9834
-
9835
- :param day: The day of the month to run this rule at. Default: - Every day of the month
9836
- :param hour: The hour to run this rule at. Default: - Every hour
9837
- :param minute: The minute to run this rule at. Default: - Every minute
9838
- :param month: The month to run this rule at. Default: - Every month
9839
- :param time_zone: Retrieve the expression for this schedule. Default: TimeZone.ETC_UTC
9840
- :param week_day: The day of the week to run this rule at. Default: - Any day of the week
9841
- :param year: The year to run this rule at. Default: - Every year
9842
-
9843
- :see: https://docs.aws.amazon.com/eventbridge/latest/userguide/scheduled-events.html#cron-expressions
9844
- :exampleMetadata: infused
9845
-
9846
- Example::
9847
-
9848
- # resource: SomeScalableResource
9849
-
9850
-
9851
- capacity = resource.auto_scale_capacity(
9852
- min_capacity=1,
9853
- max_capacity=50
9854
- )
9855
-
9856
- capacity.scale_on_schedule("PrescaleInTheMorning",
9857
- schedule=appscaling.Schedule.cron(hour="8", minute="0"),
9858
- min_capacity=20
9859
- )
9860
-
9861
- capacity.scale_on_schedule("AllowDownscalingAtNight",
9862
- schedule=appscaling.Schedule.cron(hour="20", minute="0"),
9863
- min_capacity=1
9864
- )
9865
- '''
9866
- if __debug__:
9867
- type_hints = typing.get_type_hints(_typecheckingstub__711a98b29f6f4218d39b8f2104b84399f7ff7301370f83e91f9309f619fd8459)
9868
- check_type(argname="argument day", value=day, expected_type=type_hints["day"])
9869
- check_type(argname="argument hour", value=hour, expected_type=type_hints["hour"])
9870
- check_type(argname="argument minute", value=minute, expected_type=type_hints["minute"])
9871
- check_type(argname="argument month", value=month, expected_type=type_hints["month"])
9872
- check_type(argname="argument time_zone", value=time_zone, expected_type=type_hints["time_zone"])
9873
- check_type(argname="argument week_day", value=week_day, expected_type=type_hints["week_day"])
9874
- check_type(argname="argument year", value=year, expected_type=type_hints["year"])
9875
- self._values: typing.Dict[builtins.str, typing.Any] = {}
9876
- if day is not None:
9877
- self._values["day"] = day
9878
- if hour is not None:
9879
- self._values["hour"] = hour
9880
- if minute is not None:
9881
- self._values["minute"] = minute
9882
- if month is not None:
9883
- self._values["month"] = month
9884
- if time_zone is not None:
9885
- self._values["time_zone"] = time_zone
9886
- if week_day is not None:
9887
- self._values["week_day"] = week_day
9888
- if year is not None:
9889
- self._values["year"] = year
9890
-
9891
- @builtins.property
9892
- def day(self) -> typing.Optional[builtins.str]:
9893
- '''The day of the month to run this rule at.
9894
-
9895
- :default: - Every day of the month
9896
- '''
9897
- result = self._values.get("day")
9898
- return typing.cast(typing.Optional[builtins.str], result)
9899
-
9900
- @builtins.property
9901
- def hour(self) -> typing.Optional[builtins.str]:
9902
- '''The hour to run this rule at.
9903
-
9904
- :default: - Every hour
9905
- '''
9906
- result = self._values.get("hour")
9907
- return typing.cast(typing.Optional[builtins.str], result)
9908
-
9909
- @builtins.property
9910
- def minute(self) -> typing.Optional[builtins.str]:
9911
- '''The minute to run this rule at.
9912
-
9913
- :default: - Every minute
9914
- '''
9915
- result = self._values.get("minute")
9916
- return typing.cast(typing.Optional[builtins.str], result)
9917
-
9918
- @builtins.property
9919
- def month(self) -> typing.Optional[builtins.str]:
9920
- '''The month to run this rule at.
9921
-
9922
- :default: - Every month
9923
- '''
9924
- result = self._values.get("month")
9925
- return typing.cast(typing.Optional[builtins.str], result)
9926
-
9927
- @builtins.property
9928
- def time_zone(self) -> typing.Optional["TimeZone"]:
9929
- '''Retrieve the expression for this schedule.
9930
-
9931
- :default: TimeZone.ETC_UTC
9932
- '''
9933
- result = self._values.get("time_zone")
9934
- return typing.cast(typing.Optional["TimeZone"], result)
9935
-
9936
- @builtins.property
9937
- def week_day(self) -> typing.Optional[builtins.str]:
9938
- '''The day of the week to run this rule at.
9939
-
9940
- :default: - Any day of the week
9941
- '''
9942
- result = self._values.get("week_day")
9943
- return typing.cast(typing.Optional[builtins.str], result)
9944
-
9945
- @builtins.property
9946
- def year(self) -> typing.Optional[builtins.str]:
9947
- '''The year to run this rule at.
9948
-
9949
- :default: - Every year
9950
- '''
9951
- result = self._values.get("year")
9952
- return typing.cast(typing.Optional[builtins.str], result)
9953
-
9954
- def __eq__(self, rhs: typing.Any) -> builtins.bool:
9955
- return isinstance(rhs, self.__class__) and rhs._values == self._values
9956
-
9957
- def __ne__(self, rhs: typing.Any) -> builtins.bool:
9958
- return not (rhs == self)
9959
-
9960
- def __repr__(self) -> str:
9961
- return "CronOptions(%s)" % ", ".join(
9962
- k + "=" + repr(v) for k, v in self._values.items()
9963
- )
9964
-
9965
-
9966
9805
  @jsii.data_type(
9967
9806
  jsii_type="aws-cdk-lib.CustomResourceProps",
9968
9807
  jsii_struct_bases=[],
@@ -19010,112 +18849,6 @@ class RoleOptions:
19010
18849
  )
19011
18850
 
19012
18851
 
19013
- class Schedule(metaclass=jsii.JSIIAbstractClass, jsii_type="aws-cdk-lib.Schedule"):
19014
- '''A Core Schedule.
19015
-
19016
- This construct is not meant to be used as is or exposed to consumers in other modules.
19017
- It is meant to be extended by other modules that require some sort of schedule implementation. All
19018
- methods in ``core.Schedule`` are protected, so that construct authors can decide which APIs to expose.
19019
-
19020
- :see: https://docs.aws.amazon.com/eventbridge/latest/userguide/scheduled-events.html
19021
- '''
19022
-
19023
- def __init__(self) -> None:
19024
- jsii.create(self.__class__, self, [])
19025
-
19026
- @jsii.member(jsii_name="protectedAt")
19027
- @builtins.classmethod
19028
- def protected_at(
19029
- cls,
19030
- date: datetime.datetime,
19031
- time_zone: typing.Optional["TimeZone"] = None,
19032
- ) -> "Schedule":
19033
- '''Construct a one-time schedule from a date.
19034
-
19035
- :param date: The date and time to use. The millisecond part will be ignored.
19036
- :param time_zone: The time zone to use for interpreting the date. Default: - UTC
19037
- '''
19038
- if __debug__:
19039
- type_hints = typing.get_type_hints(_typecheckingstub__1cb4b012c6f362f2cb50330d56c7cc48f8ea01d6ad2f939d11aff54eed9b8f11)
19040
- check_type(argname="argument date", value=date, expected_type=type_hints["date"])
19041
- check_type(argname="argument time_zone", value=time_zone, expected_type=type_hints["time_zone"])
19042
- return typing.cast("Schedule", jsii.sinvoke(cls, "protectedAt", [date, time_zone]))
19043
-
19044
- @jsii.member(jsii_name="protectedCron")
19045
- @builtins.classmethod
19046
- def protected_cron(
19047
- cls,
19048
- options: typing.Union[CronOptions, typing.Dict[builtins.str, typing.Any]],
19049
- module: typing.Optional[builtins.str] = None,
19050
- ) -> "Schedule":
19051
- '''Create a schedule from a set of cron fields.
19052
-
19053
- :param options: -
19054
- :param module: the module calling protectedCron, if you want module-specific warnings (i.e. aws-applicationautoscaling).
19055
- '''
19056
- if __debug__:
19057
- type_hints = typing.get_type_hints(_typecheckingstub__a1f6cdcd7e92fb975f81aa7ba86b9ac87bb2e5746067b4bf115114f51c479f15)
19058
- check_type(argname="argument options", value=options, expected_type=type_hints["options"])
19059
- check_type(argname="argument module", value=module, expected_type=type_hints["module"])
19060
- return typing.cast("Schedule", jsii.sinvoke(cls, "protectedCron", [options, module]))
19061
-
19062
- @jsii.member(jsii_name="protectedExpression")
19063
- @builtins.classmethod
19064
- def protected_expression(
19065
- cls,
19066
- expression: builtins.str,
19067
- time_zone: typing.Optional["TimeZone"] = None,
19068
- ) -> "Schedule":
19069
- '''Construct a schedule from a literal schedule expression.
19070
-
19071
- :param expression: The expression to use. Must be in a format that EventBridge will recognize
19072
- :param time_zone: The time zone, if applicable. This is only valid for 'at' and 'cron' expressions
19073
- '''
19074
- if __debug__:
19075
- type_hints = typing.get_type_hints(_typecheckingstub__6da81a3fbf3b9055fbfc2a7583560cef8c345bea7fb99ddefeab1a67a3ac80ed)
19076
- check_type(argname="argument expression", value=expression, expected_type=type_hints["expression"])
19077
- check_type(argname="argument time_zone", value=time_zone, expected_type=type_hints["time_zone"])
19078
- return typing.cast("Schedule", jsii.sinvoke(cls, "protectedExpression", [expression, time_zone]))
19079
-
19080
- @jsii.member(jsii_name="protectedRate")
19081
- @builtins.classmethod
19082
- def protected_rate(cls, duration: Duration) -> "Schedule":
19083
- '''Construct a schedule from an interval and a time unit.
19084
-
19085
- Rates may be defined with any unit of time, but when converted into minutes, the duration must be a positive whole number of minutes.
19086
-
19087
- :param duration: -
19088
- '''
19089
- if __debug__:
19090
- type_hints = typing.get_type_hints(_typecheckingstub__314888db3e6caacd852653adaa683a73164fbc78b431536b7534affc104074b7)
19091
- check_type(argname="argument duration", value=duration, expected_type=type_hints["duration"])
19092
- return typing.cast("Schedule", jsii.sinvoke(cls, "protectedRate", [duration]))
19093
-
19094
- @builtins.property
19095
- @jsii.member(jsii_name="expressionString")
19096
- @abc.abstractmethod
19097
- def expression_string(self) -> builtins.str:
19098
- '''Retrieve the expression for this schedule.'''
19099
- ...
19100
-
19101
- @builtins.property
19102
- @jsii.member(jsii_name="timeZone")
19103
- def time_zone(self) -> typing.Optional["TimeZone"]:
19104
- '''The timezone of the expression, if applicable.'''
19105
- return typing.cast(typing.Optional["TimeZone"], jsii.get(self, "timeZone"))
19106
-
19107
-
19108
- class _ScheduleProxy(Schedule):
19109
- @builtins.property
19110
- @jsii.member(jsii_name="expressionString")
19111
- def expression_string(self) -> builtins.str:
19112
- '''Retrieve the expression for this schedule.'''
19113
- return typing.cast(builtins.str, jsii.get(self, "expressionString"))
19114
-
19115
- # Adding a "__jsii_proxy_class__(): typing.Type" function to the abstract class
19116
- typing.cast(typing.Any, Schedule).__jsii_proxy_class__ = lambda : _ScheduleProxy
19117
-
19118
-
19119
18852
  class ScopedAws(metaclass=jsii.JSIIMeta, jsii_type="aws-cdk-lib.ScopedAws"):
19120
18853
  '''Accessor for scoped pseudo parameters.
19121
18854
 
@@ -33313,7 +33046,6 @@ __all__ = [
33313
33046
  "CliCredentialsStackSynthesizerProps",
33314
33047
  "ContextProvider",
33315
33048
  "CopyOptions",
33316
- "CronOptions",
33317
33049
  "CustomResource",
33318
33050
  "CustomResourceProps",
33319
33051
  "CustomResourceProvider",
@@ -33416,7 +33148,6 @@ __all__ = [
33416
33148
  "ResourceProps",
33417
33149
  "ReverseOptions",
33418
33150
  "RoleOptions",
33419
- "Schedule",
33420
33151
  "ScopedAws",
33421
33152
  "SecretValue",
33422
33153
  "SecretsManagerSecretOptions",
@@ -34975,19 +34706,6 @@ def _typecheckingstub__80d5759670f4f104ff92870b1bbd513c39e43f1023a912e9dbdce77f9
34975
34706
  """Type checking stubs"""
34976
34707
  pass
34977
34708
 
34978
- def _typecheckingstub__711a98b29f6f4218d39b8f2104b84399f7ff7301370f83e91f9309f619fd8459(
34979
- *,
34980
- day: typing.Optional[builtins.str] = None,
34981
- hour: typing.Optional[builtins.str] = None,
34982
- minute: typing.Optional[builtins.str] = None,
34983
- month: typing.Optional[builtins.str] = None,
34984
- time_zone: typing.Optional[TimeZone] = None,
34985
- week_day: typing.Optional[builtins.str] = None,
34986
- year: typing.Optional[builtins.str] = None,
34987
- ) -> None:
34988
- """Type checking stubs"""
34989
- pass
34990
-
34991
34709
  def _typecheckingstub__9dc07c260551c6e828a1b20303b5a44e226e85166f6249c94e31d02717edd2f7(
34992
34710
  *,
34993
34711
  service_token: builtins.str,
@@ -36248,33 +35966,6 @@ def _typecheckingstub__350c3eeb771368884765de415edb2b16931d742fbdb5253af2222e0e8
36248
35966
  """Type checking stubs"""
36249
35967
  pass
36250
35968
 
36251
- def _typecheckingstub__1cb4b012c6f362f2cb50330d56c7cc48f8ea01d6ad2f939d11aff54eed9b8f11(
36252
- date: datetime.datetime,
36253
- time_zone: typing.Optional[TimeZone] = None,
36254
- ) -> None:
36255
- """Type checking stubs"""
36256
- pass
36257
-
36258
- def _typecheckingstub__a1f6cdcd7e92fb975f81aa7ba86b9ac87bb2e5746067b4bf115114f51c479f15(
36259
- options: typing.Union[CronOptions, typing.Dict[builtins.str, typing.Any]],
36260
- module: typing.Optional[builtins.str] = None,
36261
- ) -> None:
36262
- """Type checking stubs"""
36263
- pass
36264
-
36265
- def _typecheckingstub__6da81a3fbf3b9055fbfc2a7583560cef8c345bea7fb99ddefeab1a67a3ac80ed(
36266
- expression: builtins.str,
36267
- time_zone: typing.Optional[TimeZone] = None,
36268
- ) -> None:
36269
- """Type checking stubs"""
36270
- pass
36271
-
36272
- def _typecheckingstub__314888db3e6caacd852653adaa683a73164fbc78b431536b7534affc104074b7(
36273
- duration: Duration,
36274
- ) -> None:
36275
- """Type checking stubs"""
36276
- pass
36277
-
36278
35969
  def _typecheckingstub__689f321e7e4b904582ab3274360f95cc0da0af0d900d2026491edbacc5078af7(
36279
35970
  scope: _constructs_77d1e7e8.Construct,
36280
35971
  ) -> None:
aws_cdk/_jsii/__init__.py CHANGED
@@ -16,7 +16,7 @@ import aws_cdk.asset_node_proxy_agent_v6._jsii
16
16
  import constructs._jsii
17
17
 
18
18
  __jsii_assembly__ = jsii.JSIIAssembly.load(
19
- "aws-cdk-lib", "2.97.0", __name__[0:-6], "aws-cdk-lib@2.97.0.jsii.tgz"
19
+ "aws-cdk-lib", "2.97.1", __name__[0:-6], "aws-cdk-lib@2.97.1.jsii.tgz"
20
20
  )
21
21
 
22
22
  __all__ = [
@@ -255,14 +255,11 @@ from .._jsii import *
255
255
  import constructs as _constructs_77d1e7e8
256
256
  from .. import (
257
257
  CfnResource as _CfnResource_9df397a6,
258
- CronOptions as _CronOptions_dd1ff9ac,
259
258
  Duration as _Duration_4839e8c3,
260
259
  IInspectable as _IInspectable_c2943556,
261
260
  IResolvable as _IResolvable_da3f097b,
262
261
  IResource as _IResource_c80c4260,
263
262
  Resource as _Resource_45bc6135,
264
- Schedule as _Schedule_e7f843a1,
265
- TimeZone as _TimeZone_cdd72ac9,
266
263
  TreeInspector as _TreeInspector_488e0dd5,
267
264
  )
268
265
  from ..aws_cloudwatch import Alarm as _Alarm_9fbab1f1, IMetric as _IMetric_c7fd29de
@@ -3260,18 +3257,17 @@ class CfnScalingPolicyProps:
3260
3257
 
3261
3258
  @jsii.data_type(
3262
3259
  jsii_type="aws-cdk-lib.aws_applicationautoscaling.CronOptions",
3263
- jsii_struct_bases=[_CronOptions_dd1ff9ac],
3260
+ jsii_struct_bases=[],
3264
3261
  name_mapping={
3265
3262
  "day": "day",
3266
3263
  "hour": "hour",
3267
3264
  "minute": "minute",
3268
3265
  "month": "month",
3269
- "time_zone": "timeZone",
3270
3266
  "week_day": "weekDay",
3271
3267
  "year": "year",
3272
3268
  },
3273
3269
  )
3274
- class CronOptions(_CronOptions_dd1ff9ac):
3270
+ class CronOptions:
3275
3271
  def __init__(
3276
3272
  self,
3277
3273
  *,
@@ -3279,11 +3275,10 @@ class CronOptions(_CronOptions_dd1ff9ac):
3279
3275
  hour: typing.Optional[builtins.str] = None,
3280
3276
  minute: typing.Optional[builtins.str] = None,
3281
3277
  month: typing.Optional[builtins.str] = None,
3282
- time_zone: typing.Optional[_TimeZone_cdd72ac9] = None,
3283
3278
  week_day: typing.Optional[builtins.str] = None,
3284
3279
  year: typing.Optional[builtins.str] = None,
3285
3280
  ) -> None:
3286
- '''(deprecated) Options to configure a cron expression.
3281
+ '''Options to configure a cron expression.
3287
3282
 
3288
3283
  All fields are strings so you can use complex expressions. Absence of
3289
3284
  a field implies '*' or '?', whichever one is appropriate.
@@ -3292,33 +3287,39 @@ class CronOptions(_CronOptions_dd1ff9ac):
3292
3287
  :param hour: The hour to run this rule at. Default: - Every hour
3293
3288
  :param minute: The minute to run this rule at. Default: - Every minute
3294
3289
  :param month: The month to run this rule at. Default: - Every month
3295
- :param time_zone: Retrieve the expression for this schedule. Default: TimeZone.ETC_UTC
3296
3290
  :param week_day: The day of the week to run this rule at. Default: - Any day of the week
3297
3291
  :param year: The year to run this rule at. Default: - Every year
3298
3292
 
3299
- :deprecated: use core.CronOptions instead
3300
-
3301
3293
  :see: https://docs.aws.amazon.com/AmazonCloudWatch/latest/events/ScheduledEvents.html#CronExpressions
3302
- :stability: deprecated
3303
- :exampleMetadata: fixture=_generated
3294
+ :exampleMetadata: infused
3304
3295
 
3305
3296
  Example::
3306
3297
 
3307
- # The code below shows an example of how to instantiate this type.
3308
- # The values are placeholders you should change.
3309
- import aws_cdk as cdk
3310
- from aws_cdk import aws_applicationautoscaling as appscaling
3298
+ # cluster: ecs.Cluster
3299
+
3300
+ load_balanced_fargate_service = ecs_patterns.ApplicationLoadBalancedFargateService(self, "Service",
3301
+ cluster=cluster,
3302
+ memory_limit_mi_b=1024,
3303
+ desired_count=1,
3304
+ cpu=512,
3305
+ task_image_options=ecsPatterns.ApplicationLoadBalancedTaskImageOptions(
3306
+ image=ecs.ContainerImage.from_registry("amazon/amazon-ecs-sample")
3307
+ )
3308
+ )
3309
+
3310
+ scalable_target = load_balanced_fargate_service.service.auto_scale_task_count(
3311
+ min_capacity=5,
3312
+ max_capacity=20
3313
+ )
3311
3314
 
3312
- # time_zone: cdk.TimeZone
3315
+ scalable_target.scale_on_schedule("DaytimeScaleDown",
3316
+ schedule=appscaling.Schedule.cron(hour="8", minute="0"),
3317
+ min_capacity=1
3318
+ )
3313
3319
 
3314
- cron_options = appscaling.CronOptions(
3315
- day="day",
3316
- hour="hour",
3317
- minute="minute",
3318
- month="month",
3319
- time_zone=time_zone,
3320
- week_day="weekDay",
3321
- year="year"
3320
+ scalable_target.scale_on_schedule("EveningRushScaleUp",
3321
+ schedule=appscaling.Schedule.cron(hour="20", minute="0"),
3322
+ min_capacity=10
3322
3323
  )
3323
3324
  '''
3324
3325
  if __debug__:
@@ -3327,7 +3328,6 @@ class CronOptions(_CronOptions_dd1ff9ac):
3327
3328
  check_type(argname="argument hour", value=hour, expected_type=type_hints["hour"])
3328
3329
  check_type(argname="argument minute", value=minute, expected_type=type_hints["minute"])
3329
3330
  check_type(argname="argument month", value=month, expected_type=type_hints["month"])
3330
- check_type(argname="argument time_zone", value=time_zone, expected_type=type_hints["time_zone"])
3331
3331
  check_type(argname="argument week_day", value=week_day, expected_type=type_hints["week_day"])
3332
3332
  check_type(argname="argument year", value=year, expected_type=type_hints["year"])
3333
3333
  self._values: typing.Dict[builtins.str, typing.Any] = {}
@@ -3339,8 +3339,6 @@ class CronOptions(_CronOptions_dd1ff9ac):
3339
3339
  self._values["minute"] = minute
3340
3340
  if month is not None:
3341
3341
  self._values["month"] = month
3342
- if time_zone is not None:
3343
- self._values["time_zone"] = time_zone
3344
3342
  if week_day is not None:
3345
3343
  self._values["week_day"] = week_day
3346
3344
  if year is not None:
@@ -3382,15 +3380,6 @@ class CronOptions(_CronOptions_dd1ff9ac):
3382
3380
  result = self._values.get("month")
3383
3381
  return typing.cast(typing.Optional[builtins.str], result)
3384
3382
 
3385
- @builtins.property
3386
- def time_zone(self) -> typing.Optional[_TimeZone_cdd72ac9]:
3387
- '''Retrieve the expression for this schedule.
3388
-
3389
- :default: TimeZone.ETC_UTC
3390
- '''
3391
- result = self._values.get("time_zone")
3392
- return typing.cast(typing.Optional[_TimeZone_cdd72ac9], result)
3393
-
3394
3383
  @builtins.property
3395
3384
  def week_day(self) -> typing.Optional[builtins.str]:
3396
3385
  '''The day of the week to run this rule at.
@@ -4329,7 +4318,6 @@ class ScalingSchedule:
4329
4318
 
4330
4319
 
4331
4320
  class Schedule(
4332
- _Schedule_e7f843a1,
4333
4321
  metaclass=jsii.JSIIAbstractClass,
4334
4322
  jsii_type="aws-cdk-lib.aws_applicationautoscaling.Schedule",
4335
4323
  ):
@@ -4361,21 +4349,15 @@ class Schedule(
4361
4349
 
4362
4350
  @jsii.member(jsii_name="at")
4363
4351
  @builtins.classmethod
4364
- def at(
4365
- cls,
4366
- moment: datetime.datetime,
4367
- time_zone: typing.Optional[_TimeZone_cdd72ac9] = None,
4368
- ) -> "Schedule":
4352
+ def at(cls, moment: datetime.datetime) -> "Schedule":
4369
4353
  '''Construct a Schedule from a moment in time.
4370
4354
 
4371
4355
  :param moment: -
4372
- :param time_zone: -
4373
4356
  '''
4374
4357
  if __debug__:
4375
4358
  type_hints = typing.get_type_hints(_typecheckingstub__9b6d7fda9383aedbe53cc8d8ade34a64e19233e11096bdf1844196644aa79458)
4376
4359
  check_type(argname="argument moment", value=moment, expected_type=type_hints["moment"])
4377
- check_type(argname="argument time_zone", value=time_zone, expected_type=type_hints["time_zone"])
4378
- return typing.cast("Schedule", jsii.sinvoke(cls, "at", [moment, time_zone]))
4360
+ return typing.cast("Schedule", jsii.sinvoke(cls, "at", [moment]))
4379
4361
 
4380
4362
  @jsii.member(jsii_name="cron")
4381
4363
  @builtins.classmethod
@@ -4386,7 +4368,6 @@ class Schedule(
4386
4368
  hour: typing.Optional[builtins.str] = None,
4387
4369
  minute: typing.Optional[builtins.str] = None,
4388
4370
  month: typing.Optional[builtins.str] = None,
4389
- time_zone: typing.Optional[_TimeZone_cdd72ac9] = None,
4390
4371
  week_day: typing.Optional[builtins.str] = None,
4391
4372
  year: typing.Optional[builtins.str] = None,
4392
4373
  ) -> "Schedule":
@@ -4396,16 +4377,14 @@ class Schedule(
4396
4377
  :param hour: The hour to run this rule at. Default: - Every hour
4397
4378
  :param minute: The minute to run this rule at. Default: - Every minute
4398
4379
  :param month: The month to run this rule at. Default: - Every month
4399
- :param time_zone: Retrieve the expression for this schedule. Default: TimeZone.ETC_UTC
4400
4380
  :param week_day: The day of the week to run this rule at. Default: - Any day of the week
4401
4381
  :param year: The year to run this rule at. Default: - Every year
4402
4382
  '''
4403
- options = _CronOptions_dd1ff9ac(
4383
+ options = CronOptions(
4404
4384
  day=day,
4405
4385
  hour=hour,
4406
4386
  minute=minute,
4407
4387
  month=month,
4408
- time_zone=time_zone,
4409
4388
  week_day=week_day,
4410
4389
  year=year,
4411
4390
  )
@@ -4414,29 +4393,21 @@ class Schedule(
4414
4393
 
4415
4394
  @jsii.member(jsii_name="expression")
4416
4395
  @builtins.classmethod
4417
- def expression(
4418
- cls,
4419
- expression: builtins.str,
4420
- time_zone: typing.Optional[_TimeZone_cdd72ac9] = None,
4421
- ) -> "Schedule":
4396
+ def expression(cls, expression: builtins.str) -> "Schedule":
4422
4397
  '''Construct a schedule from a literal schedule expression.
4423
4398
 
4424
4399
  :param expression: The expression to use. Must be in a format that Application AutoScaling will recognize
4425
- :param time_zone: -
4426
4400
  '''
4427
4401
  if __debug__:
4428
4402
  type_hints = typing.get_type_hints(_typecheckingstub__7e25a6639f36857385bcf857e79dd3e959c720c58729794a75fde1193754cc9d)
4429
4403
  check_type(argname="argument expression", value=expression, expected_type=type_hints["expression"])
4430
- check_type(argname="argument time_zone", value=time_zone, expected_type=type_hints["time_zone"])
4431
- return typing.cast("Schedule", jsii.sinvoke(cls, "expression", [expression, time_zone]))
4404
+ return typing.cast("Schedule", jsii.sinvoke(cls, "expression", [expression]))
4432
4405
 
4433
4406
  @jsii.member(jsii_name="rate")
4434
4407
  @builtins.classmethod
4435
4408
  def rate(cls, duration: _Duration_4839e8c3) -> "Schedule":
4436
4409
  '''Construct a schedule from an interval and a time unit.
4437
4410
 
4438
- Must be a whole number of seconds.
4439
-
4440
4411
  :param duration: -
4441
4412
  '''
4442
4413
  if __debug__:
@@ -4444,12 +4415,20 @@ class Schedule(
4444
4415
  check_type(argname="argument duration", value=duration, expected_type=type_hints["duration"])
4445
4416
  return typing.cast("Schedule", jsii.sinvoke(cls, "rate", [duration]))
4446
4417
 
4418
+ @builtins.property
4419
+ @jsii.member(jsii_name="expressionString")
4420
+ @abc.abstractmethod
4421
+ def expression_string(self) -> builtins.str:
4422
+ '''Retrieve the expression for this schedule.'''
4423
+ ...
4447
4424
 
4448
- class _ScheduleProxy(
4449
- Schedule,
4450
- jsii.proxy_for(_Schedule_e7f843a1), # type: ignore[misc]
4451
- ):
4452
- pass
4425
+
4426
+ class _ScheduleProxy(Schedule):
4427
+ @builtins.property
4428
+ @jsii.member(jsii_name="expressionString")
4429
+ def expression_string(self) -> builtins.str:
4430
+ '''Retrieve the expression for this schedule.'''
4431
+ return typing.cast(builtins.str, jsii.get(self, "expressionString"))
4453
4432
 
4454
4433
  # Adding a "__jsii_proxy_class__(): typing.Type" function to the abstract class
4455
4434
  typing.cast(typing.Any, Schedule).__jsii_proxy_class__ = lambda : _ScheduleProxy
@@ -5946,7 +5925,6 @@ def _typecheckingstub__6de063595e26cfdffe8cc2657f923bb73bea86791277de8f39a31cb70
5946
5925
  hour: typing.Optional[builtins.str] = None,
5947
5926
  minute: typing.Optional[builtins.str] = None,
5948
5927
  month: typing.Optional[builtins.str] = None,
5949
- time_zone: typing.Optional[_TimeZone_cdd72ac9] = None,
5950
5928
  week_day: typing.Optional[builtins.str] = None,
5951
5929
  year: typing.Optional[builtins.str] = None,
5952
5930
  ) -> None:
@@ -6065,14 +6043,12 @@ def _typecheckingstub__57aef750eb5141016e0f252e7b49eacfa61419872935a6645e358d0c9
6065
6043
 
6066
6044
  def _typecheckingstub__9b6d7fda9383aedbe53cc8d8ade34a64e19233e11096bdf1844196644aa79458(
6067
6045
  moment: datetime.datetime,
6068
- time_zone: typing.Optional[_TimeZone_cdd72ac9] = None,
6069
6046
  ) -> None:
6070
6047
  """Type checking stubs"""
6071
6048
  pass
6072
6049
 
6073
6050
  def _typecheckingstub__7e25a6639f36857385bcf857e79dd3e959c720c58729794a75fde1193754cc9d(
6074
6051
  expression: builtins.str,
6075
- time_zone: typing.Optional[_TimeZone_cdd72ac9] = None,
6076
6052
  ) -> None:
6077
6053
  """Type checking stubs"""
6078
6054
  pass