1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

Skip shard count test in check mode. (#3329)

The shard count is not available in check mode.
This commit is contained in:
Matt Clay 2016-10-31 17:15:28 -07:00
parent 16896194a8
commit db0ac4936b

View file

@ -857,7 +857,7 @@ def create_stream(client, stream_name, number_of_shards=1, retention_period=None
stream_found, stream_msg, current_stream = ( stream_found, stream_msg, current_stream = (
find_stream(client, stream_name, check_mode=check_mode) find_stream(client, stream_name, check_mode=check_mode)
) )
if stream_found: if stream_found and not check_mode:
if current_stream['ShardsCount'] != number_of_shards: if current_stream['ShardsCount'] != number_of_shards:
err_msg = 'Can not change the number of shards in a Kinesis Stream' err_msg = 'Can not change the number of shards in a Kinesis Stream'
return success, changed, err_msg, results return success, changed, err_msg, results