Skip to content

Commit

Permalink
The integration timeout can now be increased beyond 29,000 millisecon…
Browse files Browse the repository at this point in the history
…ds. Removing upper limit.
  • Loading branch information
William McLean committed Jul 31, 2024
1 parent 05fb8a2 commit 4286af6
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
7 changes: 5 additions & 2 deletions troposphere/validators/apigateway.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# See LICENSE file for full license.


from . import integer_range, json_checker, positive_integer, tags_or_list
from . import json_checker, positive_integer, tags_or_list


def dict_or_string(x):
Expand All @@ -29,7 +29,10 @@ def validate_timeout_in_millis(x):
"""
Property: Integration.TimeoutInMillis
"""
return integer_range(50, 29000)(x)
int(x)
if x < 50:
raise ValueError(f"TimeoutInMillis of {x} must be greater than 50")
return x


def validate_authorizer_ttl(ttl_value):
Expand Down
7 changes: 5 additions & 2 deletions troposphere/validators/apigatewayv2.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# See LICENSE file for full license.


from . import integer_range, json_checker, positive_integer
from . import json_checker, positive_integer


def dict_or_string(x):
Expand All @@ -21,7 +21,10 @@ def validate_timeout_in_millis(x):
"""
Property: Integration.TimeoutInMillis
"""
return integer_range(50, 29000)(x)
int(x)
if x < 50:
raise ValueError(f"TimeoutInMillis of {x} must be greater than 50")
return x


def validate_integration_type(integration_type):
Expand Down

0 comments on commit 4286af6

Please sign in to comment.