smithy4s.com.amazonaws.kinesis.UpdateShardCountInput.scala Maven / Gradle / Ivy
Show all versions of kinesis4cats-smithy4s-client_3 Show documentation
package com.amazonaws.kinesis
import smithy4s.Hints
import smithy4s.Schema
import smithy4s.ShapeId
import smithy4s.ShapeTag
import smithy4s.schema.Schema.struct
/** @param StreamName
* The name of the stream.
* @param TargetShardCount
* The new number of shards. This value has the following default limits. By default, you
* cannot do the following:
*
* -
*
Set this value to more than double your current shard count for a
* stream.
*
* -
*
Set this value below half your current shard count for a stream.
*
* -
*
Set this value to more than 10000 shards in a stream (the default limit for
* shard count per stream is 10000 per account per region), unless you request a
* limit increase.
*
* -
*
Scale a stream with more than 10000 shards down unless you set this value to
* less than 10000 shards.
*
*
* @param ScalingType
* The scaling type. Uniform scaling creates shards of equal size.
* @param StreamARN
* The ARN of the stream.
*/
final case class UpdateShardCountInput(targetShardCount: PositiveIntegerObject, scalingType: ScalingType, streamName: Option[StreamName] = None, streamARN: Option[StreamARN] = None)
object UpdateShardCountInput extends ShapeTag.Companion[UpdateShardCountInput] {
val id: ShapeId = ShapeId("com.amazonaws.kinesis", "UpdateShardCountInput")
val hints: Hints = Hints(
smithy.api.Input(),
).lazily
// constructor using the original order from the spec
private def make(streamName: Option[StreamName], targetShardCount: PositiveIntegerObject, scalingType: ScalingType, streamARN: Option[StreamARN]): UpdateShardCountInput = UpdateShardCountInput(targetShardCount, scalingType, streamName, streamARN)
implicit val schema: Schema[UpdateShardCountInput] = struct(
StreamName.schema.optional[UpdateShardCountInput]("StreamName", _.streamName).addHints(smithy.api.Documentation("The name of the stream.
")),
PositiveIntegerObject.schema.required[UpdateShardCountInput]("TargetShardCount", _.targetShardCount).addHints(smithy.api.Documentation("The new number of shards. This value has the following default limits. By default, you\n cannot do the following:
\n \n - \n
Set this value to more than double your current shard count for a\n stream.
\n \n - \n
Set this value below half your current shard count for a stream.
\n \n - \n
Set this value to more than 10000 shards in a stream (the default limit for\n shard count per stream is 10000 per account per region), unless you request a\n limit increase.
\n \n - \n
Scale a stream with more than 10000 shards down unless you set this value to\n less than 10000 shards.
\n \n
")),
ScalingType.schema.required[UpdateShardCountInput]("ScalingType", _.scalingType).addHints(smithy.api.Documentation("The scaling type. Uniform scaling creates shards of equal size.
")),
StreamARN.schema.optional[UpdateShardCountInput]("StreamARN", _.streamARN).addHints(smithy.api.Documentation("The ARN of the stream.
")),
)(make).withId(id).addHints(hints)
}