AWS SDK

AWS SDK

rev. b9ccf3dabc550b0fbe85e785b19c58a2472f505e..96418c2288c67c1dde0d5d93cadadbf52fc820f4 (ignoring whitespace)

Files changed:

tmp-codegen-diff/services/bedrock/common/test/aws/sdk/kotlin/services/bedrock/BedrockEnvironmentBearerTokenTest.kt

@@ -0,1 +107,172 @@
           1  +
/*
           2  +
 * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
           3  +
 * SPDX-License-Identifier: Apache-2.0
           4  +
 */
           5  +
    1      6   
package aws.sdk.kotlin.services.bedrock
    2      7   
    3      8   
import aws.sdk.kotlin.services.bedrock.auth.finalizeBearerTokenConfig
    4      9   
import aws.smithy.kotlin.runtime.auth.AuthSchemeId
    5     10   
import aws.smithy.kotlin.runtime.collections.Attributes
    6     11   
import aws.smithy.kotlin.runtime.collections.emptyAttributes
    7     12   
import aws.smithy.kotlin.runtime.http.Headers
    8     13   
import aws.smithy.kotlin.runtime.http.HttpBody
    9     14   
import aws.smithy.kotlin.runtime.http.HttpCall
   10     15   
import aws.smithy.kotlin.runtime.http.HttpStatusCode
   11     16   
import aws.smithy.kotlin.runtime.http.auth.BearerToken
   12     17   
import aws.smithy.kotlin.runtime.http.auth.BearerTokenProvider
   13     18   
import aws.smithy.kotlin.runtime.http.engine.HttpClientEngine
   14     19   
import aws.smithy.kotlin.runtime.http.engine.HttpClientEngineBase
   15     20   
import aws.smithy.kotlin.runtime.http.engine.HttpClientEngineConfig
   16     21   
import aws.smithy.kotlin.runtime.http.request.HttpRequest
   17     22   
import aws.smithy.kotlin.runtime.http.response.HttpResponse
   18         -
import aws.smithy.kotlin.runtime.io.use
   19     23   
import aws.smithy.kotlin.runtime.operation.ExecutionContext
   20     24   
import aws.smithy.kotlin.runtime.time.Instant
   21     25   
import aws.smithy.kotlin.runtime.util.TestPlatformProvider
   22     26   
import kotlinx.coroutines.test.runTest
          27  +
import kotlin.test.Test
   23     28   
import kotlin.test.assertEquals
   24     29   
import kotlin.test.assertNotNull
          30  +
import kotlin.test.assertTrue
   25     31   
   26     32   
class BedrockEnvironmentBearerTokenTest {
   27         -
    private fun mockHttpClient(handler: (HttpRequest) -> HttpResponse): HttpClientEngine {
   28         -
        return object : HttpClientEngineBase("test engine") {
          33  +
    private fun mockHttpClient(handler: (HttpRequest) -> HttpResponse): HttpClientEngine =
          34  +
        object : HttpClientEngineBase("test engine") {
   29     35   
            override val config: HttpClientEngineConfig = HttpClientEngineConfig.Default
   30     36   
   31     37   
            override suspend fun roundTrip(context: ExecutionContext, request: HttpRequest): HttpCall {
   32     38   
                val response = handler(request)
   33     39   
                return HttpCall(request, response, Instant.now(), Instant.now())
   34     40   
            }
   35     41   
        }
   36         -
    }
   37     42   
   38     43   
    private val mockPlatformProvider = TestPlatformProvider(
   39     44   
        env = mapOf("AWS_BEARER_TOKEN_BEDROCK" to "bedrock-token"),
   40     45   
    )
   41     46   
          47  +
    @Test
   42     48   
    fun testAuthSchemePreferenceConfigured() = runTest {
   43         -
        val builder = BedrockClient.Builder()
   44     49   
        val expectedAuthSchemePreference = listOf(AuthSchemeId.HttpBearer)
          50  +
        val builder = BedrockClient.Builder()
          51  +
   45     52   
        finalizeBearerTokenConfig(builder, mockPlatformProvider)
          53  +
   46     54   
        assertEquals(expectedAuthSchemePreference, builder.config.authSchemePreference)
   47     55   
    }
   48     56   
          57  +
    @Test
   49     58   
    fun testBearerAuthSchemePromotedToFirst() = runTest {
          59  +
        val expectedAuthSchemePreference = listOf(AuthSchemeId.HttpBearer, AuthSchemeId.AwsSigV4)
   50     60   
        val builder = BedrockClient.Builder()
          61  +
   51     62   
        builder.config.authSchemePreference = listOf(AuthSchemeId.AwsSigV4)
   52     63   
        finalizeBearerTokenConfig(builder, mockPlatformProvider)
   53         -
        val expectedAuthSchemePreference = listOf(AuthSchemeId.HttpBearer, AuthSchemeId.AwsSigV4)
   54     64   
        assertEquals(expectedAuthSchemePreference, builder.config.authSchemePreference)
   55     65   
   56     66   
        builder.config.authSchemePreference = listOf(AuthSchemeId.AwsSigV4, AuthSchemeId.HttpBearer)
          67  +
        finalizeBearerTokenConfig(builder, mockPlatformProvider)
   57     68   
        assertEquals(expectedAuthSchemePreference, builder.config.authSchemePreference)
   58     69   
    }
   59     70   
          71  +
    @Test
   60     72   
    fun testBearerTokenProviderConfigured() = runTest {
   61     73   
        val builder = BedrockClient.Builder()
   62     74   
        finalizeBearerTokenConfig(builder, mockPlatformProvider)
          75  +
   63     76   
        assertNotNull(builder.config.bearerTokenProvider)
   64     77   
        val token = builder.config.bearerTokenProvider!!.resolve()
   65     78   
        assertNotNull(token)
   66     79   
        assertEquals("bedrock-token", token.token)
   67     80   
    }
   68     81   
          82  +
    @Test
          83  +
    fun testBearerTokenSourcingPrecedence() = runTest {
          84  +
        val builder = BedrockClient.Builder()
          85  +
          86  +
        finalizeBearerTokenConfig(
          87  +
            builder,
          88  +
            TestPlatformProvider(
          89  +
                env = mapOf("AWS_BEARER_TOKEN_BEDROCK" to "env-bedrock-token"),
          90  +
                props = mapOf("aws.bearerTokenBedrock" to "sys-props-bedrock-token"),
          91  +
            ),
          92  +
        )
          93  +
          94  +
        val token = builder.config.bearerTokenProvider!!.resolve()
          95  +
        assertEquals("sys-props-bedrock-token", token.token)
          96  +
    }
          97  +
          98  +
    @Test
   69     99   
    fun testExplicitProviderTakesPrecedence() = runTest {
   70    100   
        val builder = BedrockClient.Builder()
         101  +
   71    102   
        builder.config.bearerTokenProvider = object : BearerTokenProvider {
   72    103   
            override suspend fun resolve(attributes: Attributes): BearerToken = object : BearerToken {
   73    104   
                override val token: String = "different-bedrock-token"
   74    105   
                override val attributes: Attributes = emptyAttributes()
   75    106   
                override val expiration: Instant? = null
   76    107   
            }
   77    108   
        }
         109  +
   78    110   
        finalizeBearerTokenConfig(builder, mockPlatformProvider)
         111  +
   79    112   
        assertNotNull(builder.config.bearerTokenProvider)
   80    113   
        val token = builder.config.bearerTokenProvider!!.resolve()
   81    114   
        assertNotNull(token)
   82    115   
        assertEquals("different-bedrock-token", token.token)
   83    116   
    }
   84    117   
         118  +
    @Test
   85    119   
    fun testBearerTokenProviderFunctionality() = runTest {
   86    120   
        var capturedAuthHeader: String? = null
   87    121   
   88         -
        BedrockClient.fromEnvironment {
   89         -
            region = "us-west-2"
   90         -
            httpClient = mockHttpClient { request ->
   91         -
                // Capture the Authorization header
         122  +
        val builder = BedrockClient.Builder().apply {
         123  +
            config.region = "us-west-2"
         124  +
            config.httpClient = mockHttpClient { request ->
   92    125   
                capturedAuthHeader = request.headers["Authorization"]
   93    126   
                HttpResponse(
   94    127   
                    status = HttpStatusCode.OK,
   95    128   
                    headers = Headers.Empty,
   96    129   
                    body = HttpBody.Empty,
   97    130   
                )
   98    131   
            }
   99         -
        }.use { client ->
         132  +
        }
         133  +
         134  +
        finalizeBearerTokenConfig(builder, mockPlatformProvider)
         135  +
         136  +
        val testClient = builder.build()
  100    137   
        // Make an api call to capture Authorization header
  101         -
            client.listFoundationModels()
         138  +
        testClient.listFoundationModels()
  102    139   
  103    140   
        assertNotNull(capturedAuthHeader)
  104    141   
        assertEquals("Bearer bedrock-token", capturedAuthHeader)
  105    142   
    }
         143  +
         144  +
    @Test
         145  +
    fun testBusinessMetricEmitted() = runTest {
         146  +
        var capturedUserAgent: String? = null
         147  +
         148  +
        val builder = BedrockClient.Builder().apply {
         149  +
            config.region = "us-west-2"
         150  +
            config.httpClient = mockHttpClient { request ->
         151  +
                capturedUserAgent = request.headers["User-Agent"]
         152  +
                HttpResponse(
         153  +
                    status = HttpStatusCode.OK,
         154  +
                    headers = Headers.Empty,
         155  +
                    body = HttpBody.Empty,
         156  +
                )
         157  +
            }
         158  +
        }
         159  +
         160  +
        finalizeBearerTokenConfig(builder, mockPlatformProvider)
         161  +
         162  +
        val testClient = builder.build()
         163  +
        // Make an api call to capture User-Agent header
         164  +
        testClient.listFoundationModels()
         165  +
         166  +
        assertNotNull(capturedUserAgent)
         167  +
        val capturedBusinessMetrics = Regex("m/([^\\s]+)").find(capturedUserAgent!!)?.value
         168  +
        assertNotNull(capturedBusinessMetrics)
         169  +
        // Check User-Agent header contains the business metric
         170  +
        assertTrue(capturedBusinessMetrics.contains("3"))
  106    171   
    }
  107    172   
}

tmp-codegen-diff/services/build.gradle.kts

@@ -1,1 +36,36 @@
    1      1   
/*
    2      2   
 * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
    3      3   
 * SPDX-License-Identifier: Apache-2.0
    4      4   
 */
    5         -
import aws.sdk.kotlin.gradle.dsl.configurePublishing
    6         -
import aws.sdk.kotlin.gradle.kmp.kotlin
           5  +
import aws.sdk.kotlin.gradle.dsl.configureNexusPublishing
           6  +
import aws.sdk.kotlin.gradle.kmp.*
    7      7   
import aws.sdk.kotlin.gradle.util.typedProp
    8      8   
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
    9      9   
import java.time.LocalDateTime
   10     10   
   11     11   
plugins {
   12     12   
    `maven-publish`
   13     13   
    `dokka-convention`
   14     14   
    alias(libs.plugins.aws.kotlin.repo.tools.kmp) apply false
   15     15   
}
   16     16   
@@ -111,111 +167,169 @@
  131    131   
    tasks.withType<org.gradle.api.tasks.testing.AbstractTestTask>().configureEach {
  132    132   
        testLogging {
  133    133   
            events("passed", "skipped", "failed")
  134    134   
            showStandardStreams = true
  135    135   
            showStackTraces = true
  136    136   
            showExceptions = true
  137    137   
            exceptionFormat = org.gradle.api.tasks.testing.logging.TestExceptionFormat.FULL
  138    138   
        }
  139    139   
    }
  140    140   
  141         -
    configurePublishing("aws-sdk-kotlin")
         141  +
    // TODO Use configurePublishing when migrating to Sonatype Publisher API / JReleaser
         142  +
    configureNexusPublishing("aws-sdk-kotlin")
         143  +
  142    144   
    publishing {
  143    145   
        publications.all {
  144    146   
            if (this !is MavenPublication) return@all
  145    147   
            project.afterEvaluate {
  146    148   
                val sdkId = project.typedProp<String>("aws.sdk.id") ?: error("service build `${project.name}` is missing `aws.sdk.id` property required for publishing")
  147    149   
                pom.properties.put("aws.sdk.id", sdkId)
  148    150   
            }
  149    151   
        }
  150    152   
    }
  151    153   
}

tmp-codegen-diff/services/codebuild/generated-src/main/kotlin/aws/sdk/kotlin/services/codebuild/CodeBuildClient.kt

@@ -143,143 +203,203 @@
  163    163   
import aws.smithy.kotlin.runtime.telemetry.TelemetryConfig
  164    164   
import aws.smithy.kotlin.runtime.telemetry.TelemetryProvider
  165    165   
import aws.smithy.kotlin.runtime.util.LazyAsyncValue
  166    166   
import kotlin.collections.List
  167    167   
import kotlin.jvm.JvmStatic
  168    168   
import kotlin.time.Duration
  169    169   
import kotlinx.coroutines.runBlocking
  170    170   
  171    171   
  172    172   
public const val ServiceId: String = "CodeBuild"
  173         -
public const val SdkVersion: String = "1.5.12-SNAPSHOT"
         173  +
public const val SdkVersion: String = "1.5.53-SNAPSHOT"
  174    174   
public const val ServiceApiVersion: String = "2016-10-06"
  175    175   
  176    176   
/**
  177    177   
 * # CodeBuild
  178    178   
 * CodeBuild is a fully managed build service in the cloud. CodeBuild compiles your source code, runs unit tests, and produces artifacts that are ready to deploy. CodeBuild eliminates the need to provision, manage, and scale your own build servers. It provides prepackaged build environments for the most popular programming languages and build tools, such as Apache Maven, Gradle, and more. You can also fully customize build environments in CodeBuild to use your own build tools. CodeBuild scales automatically to meet peak build requests. You pay only for the build time you consume. For more information about CodeBuild, see the *[CodeBuild User Guide](https://docs.aws.amazon.com/codebuild/latest/userguide/welcome.html).*
  179    179   
 */
  180    180   
public interface CodeBuildClient : SdkClient {
  181    181   
    /**
  182    182   
     * CodeBuildClient's configuration
  183    183   
     */

tmp-codegen-diff/services/codebuild/generated-src/main/kotlin/aws/sdk/kotlin/services/codebuild/endpoints/internal/Partitions.kt

@@ -14,14 +73,75 @@
   34     34   
            "ap-southeast-1" to PartitionConfig(
   35     35   
            ),
   36     36   
            "ap-southeast-2" to PartitionConfig(
   37     37   
            ),
   38     38   
            "ap-southeast-3" to PartitionConfig(
   39     39   
            ),
   40     40   
            "ap-southeast-4" to PartitionConfig(
   41     41   
            ),
   42     42   
            "ap-southeast-5" to PartitionConfig(
   43     43   
            ),
          44  +
            "ap-southeast-6" to PartitionConfig(
          45  +
            ),
   44     46   
            "ap-southeast-7" to PartitionConfig(
   45     47   
            ),
   46     48   
            "aws-global" to PartitionConfig(
   47     49   
            ),
   48     50   
            "ca-central-1" to PartitionConfig(
   49     51   
            ),
   50     52   
            "ca-west-1" to PartitionConfig(
   51     53   
            ),
   52     54   
            "eu-central-1" to PartitionConfig(
   53     55   
            ),
@@ -87,89 +228,230 @@
  107    109   
        baseConfig = PartitionConfig(
  108    110   
            name = "aws-cn",
  109    111   
            dnsSuffix = "amazonaws.com.cn",
  110    112   
            dualStackDnsSuffix = "api.amazonwebservices.com.cn",
  111    113   
            supportsFIPS = true,
  112    114   
            supportsDualStack = true,
  113    115   
            implicitGlobalRegion = "cn-northwest-1",
  114    116   
        ),
  115    117   
    ),
  116    118   
    Partition(
  117         -
        id = "aws-us-gov",
  118         -
        regionRegex = Regex("^us\\-gov\\-\\w+\\-\\d+$"),
         119  +
        id = "aws-eusc",
         120  +
        regionRegex = Regex("^eusc\\-(de)\\-\\w+\\-\\d+$"),
  119    121   
        regions = mapOf(
  120         -
            "aws-us-gov-global" to PartitionConfig(
  121         -
            ),
  122         -
            "us-gov-east-1" to PartitionConfig(
  123         -
            ),
  124         -
            "us-gov-west-1" to PartitionConfig(
         122  +
            "eusc-de-east-1" to PartitionConfig(
  125    123   
            ),
  126    124   
        ),
  127    125   
        baseConfig = PartitionConfig(
  128         -
            name = "aws-us-gov",
  129         -
            dnsSuffix = "amazonaws.com",
  130         -
            dualStackDnsSuffix = "api.aws",
         126  +
            name = "aws-eusc",
         127  +
            dnsSuffix = "amazonaws.eu",
         128  +
            dualStackDnsSuffix = "api.amazonwebservices.eu",
  131    129   
            supportsFIPS = true,
  132    130   
            supportsDualStack = true,
  133         -
            implicitGlobalRegion = "us-gov-west-1",
         131  +
            implicitGlobalRegion = "eusc-de-east-1",
  134    132   
        ),
  135    133   
    ),
  136    134   
    Partition(
  137    135   
        id = "aws-iso",
  138    136   
        regionRegex = Regex("^us\\-iso\\-\\w+\\-\\d+$"),
  139    137   
        regions = mapOf(
  140    138   
            "aws-iso-global" to PartitionConfig(
  141    139   
            ),
  142    140   
            "us-iso-east-1" to PartitionConfig(
  143    141   
            ),
  144    142   
            "us-iso-west-1" to PartitionConfig(
  145    143   
            ),
  146    144   
        ),
  147    145   
        baseConfig = PartitionConfig(
  148    146   
            name = "aws-iso",
  149    147   
            dnsSuffix = "c2s.ic.gov",
  150         -
            dualStackDnsSuffix = "c2s.ic.gov",
         148  +
            dualStackDnsSuffix = "api.aws.ic.gov",
  151    149   
            supportsFIPS = true,
  152         -
            supportsDualStack = false,
         150  +
            supportsDualStack = true,
  153    151   
            implicitGlobalRegion = "us-iso-east-1",
  154    152   
        ),
  155    153   
    ),
  156    154   
    Partition(
  157    155   
        id = "aws-iso-b",
  158    156   
        regionRegex = Regex("^us\\-isob\\-\\w+\\-\\d+$"),
  159    157   
        regions = mapOf(
  160    158   
            "aws-iso-b-global" to PartitionConfig(
  161    159   
            ),
  162    160   
            "us-isob-east-1" to PartitionConfig(
  163    161   
            ),
  164    162   
        ),
  165    163   
        baseConfig = PartitionConfig(
  166    164   
            name = "aws-iso-b",
  167    165   
            dnsSuffix = "sc2s.sgov.gov",
  168         -
            dualStackDnsSuffix = "sc2s.sgov.gov",
         166  +
            dualStackDnsSuffix = "api.aws.scloud",
  169    167   
            supportsFIPS = true,
  170         -
            supportsDualStack = false,
         168  +
            supportsDualStack = true,
  171    169   
            implicitGlobalRegion = "us-isob-east-1",
  172    170   
        ),
  173    171   
    ),
  174    172   
    Partition(
  175    173   
        id = "aws-iso-e",
  176    174   
        regionRegex = Regex("^eu\\-isoe\\-\\w+\\-\\d+$"),
  177    175   
        regions = mapOf(
  178    176   
            "aws-iso-e-global" to PartitionConfig(
  179    177   
            ),
  180    178   
            "eu-isoe-west-1" to PartitionConfig(
  181    179   
            ),
  182    180   
        ),
  183    181   
        baseConfig = PartitionConfig(
  184    182   
            name = "aws-iso-e",
  185    183   
            dnsSuffix = "cloud.adc-e.uk",
  186         -
            dualStackDnsSuffix = "cloud.adc-e.uk",
         184  +
            dualStackDnsSuffix = "api.cloud-aws.adc-e.uk",
  187    185   
            supportsFIPS = true,
  188         -
            supportsDualStack = false,
         186  +
            supportsDualStack = true,
  189    187   
            implicitGlobalRegion = "eu-isoe-west-1",
  190    188   
        ),
  191    189   
    ),
  192    190   
    Partition(
  193    191   
        id = "aws-iso-f",
  194    192   
        regionRegex = Regex("^us\\-isof\\-\\w+\\-\\d+$"),
  195    193   
        regions = mapOf(
  196    194   
            "aws-iso-f-global" to PartitionConfig(
  197    195   
            ),
  198    196   
            "us-isof-east-1" to PartitionConfig(
  199    197   
            ),
  200    198   
            "us-isof-south-1" to PartitionConfig(
  201    199   
            ),
  202    200   
        ),
  203    201   
        baseConfig = PartitionConfig(
  204    202   
            name = "aws-iso-f",
  205    203   
            dnsSuffix = "csp.hci.ic.gov",
  206         -
            dualStackDnsSuffix = "csp.hci.ic.gov",
         204  +
            dualStackDnsSuffix = "api.aws.hci.ic.gov",
  207    205   
            supportsFIPS = true,
  208         -
            supportsDualStack = false,
         206  +
            supportsDualStack = true,
  209    207   
            implicitGlobalRegion = "us-isof-south-1",
  210    208   
        ),
  211    209   
    ),
  212    210   
    Partition(
  213         -
        id = "aws-eusc",
  214         -
        regionRegex = Regex("^eusc\\-(de)\\-\\w+\\-\\d+$"),
         211  +
        id = "aws-us-gov",
         212  +
        regionRegex = Regex("^us\\-gov\\-\\w+\\-\\d+$"),
  215    213   
        regions = mapOf(
  216         -
            "eusc-de-east-1" to PartitionConfig(
         214  +
            "aws-us-gov-global" to PartitionConfig(
         215  +
            ),
         216  +
            "us-gov-east-1" to PartitionConfig(
         217  +
            ),
         218  +
            "us-gov-west-1" to PartitionConfig(
  217    219   
            ),
  218    220   
        ),
  219    221   
        baseConfig = PartitionConfig(
  220         -
            name = "aws-eusc",
  221         -
            dnsSuffix = "amazonaws.eu",
  222         -
            dualStackDnsSuffix = "amazonaws.eu",
         222  +
            name = "aws-us-gov",
         223  +
            dnsSuffix = "amazonaws.com",
         224  +
            dualStackDnsSuffix = "api.aws",
  223    225   
            supportsFIPS = true,
  224         -
            supportsDualStack = false,
  225         -
            implicitGlobalRegion = "eusc-de-east-1",
         226  +
            supportsDualStack = true,
         227  +
            implicitGlobalRegion = "us-gov-west-1",
  226    228   
        ),
  227    229   
    ),
  228    230   
)

tmp-codegen-diff/services/codebuild/generated-src/main/kotlin/aws/sdk/kotlin/services/codebuild/model/CreateWebhookRequest.kt

@@ -6,6 +149,168 @@
   26     26   
    /**
   27     27   
     * If manualCreation is true, CodeBuild doesn't create a webhook in GitHub and instead returns `payloadUrl` and `secret` values for the webhook. The `payloadUrl` and `secret` values in the output can be used to manually create a webhook within GitHub.
   28     28   
     *
   29     29   
     * `manualCreation` is only available for GitHub webhooks.
   30     30   
     */
   31     31   
    public val manualCreation: kotlin.Boolean? = builder.manualCreation
   32     32   
    /**
   33     33   
     * The name of the CodeBuild project.
   34     34   
     */
   35     35   
    public val projectName: kotlin.String? = builder.projectName
          36  +
    /**
          37  +
     * A PullRequestBuildPolicy object that defines comment-based approval requirements for triggering builds on pull requests. This policy helps control when automated builds are executed based on contributor permissions and approval workflows.
          38  +
     */
          39  +
    public val pullRequestBuildPolicy: aws.sdk.kotlin.services.codebuild.model.PullRequestBuildPolicy? = builder.pullRequestBuildPolicy
   36     40   
    /**
   37     41   
     * The scope configuration for global or organization webhooks.
   38     42   
     *
   39     43   
     * Global or organization webhooks are only available for GitHub and Github Enterprise webhooks.
   40     44   
     */
   41     45   
    public val scopeConfiguration: aws.sdk.kotlin.services.codebuild.model.ScopeConfiguration? = builder.scopeConfiguration
   42     46   
   43     47   
    public companion object {
   44     48   
        public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.codebuild.model.CreateWebhookRequest = Builder().apply(block).build()
   45     49   
    }
   46     50   
   47     51   
    override fun toString(): kotlin.String = buildString {
   48     52   
        append("CreateWebhookRequest(")
   49     53   
        append("branchFilter=$branchFilter,")
   50     54   
        append("buildType=$buildType,")
   51     55   
        append("filterGroups=$filterGroups,")
   52     56   
        append("manualCreation=$manualCreation,")
   53     57   
        append("projectName=$projectName,")
          58  +
        append("pullRequestBuildPolicy=$pullRequestBuildPolicy,")
   54     59   
        append("scopeConfiguration=$scopeConfiguration")
   55     60   
        append(")")
   56     61   
    }
   57     62   
   58     63   
    override fun hashCode(): kotlin.Int {
   59     64   
        var result = branchFilter?.hashCode() ?: 0
   60     65   
        result = 31 * result + (this.buildType?.hashCode() ?: 0)
   61     66   
        result = 31 * result + (this.filterGroups?.hashCode() ?: 0)
   62     67   
        result = 31 * result + (this.manualCreation?.hashCode() ?: 0)
   63     68   
        result = 31 * result + (this.projectName?.hashCode() ?: 0)
          69  +
        result = 31 * result + (this.pullRequestBuildPolicy?.hashCode() ?: 0)
   64     70   
        result = 31 * result + (this.scopeConfiguration?.hashCode() ?: 0)
   65     71   
        return result
   66     72   
    }
   67     73   
   68     74   
    override fun equals(other: kotlin.Any?): kotlin.Boolean {
   69     75   
        if (this === other) return true
   70     76   
        if (other == null || this::class != other::class) return false
   71     77   
   72     78   
        other as CreateWebhookRequest
   73     79   
   74     80   
        if (branchFilter != other.branchFilter) return false
   75     81   
        if (buildType != other.buildType) return false
   76     82   
        if (filterGroups != other.filterGroups) return false
   77     83   
        if (manualCreation != other.manualCreation) return false
   78     84   
        if (projectName != other.projectName) return false
          85  +
        if (pullRequestBuildPolicy != other.pullRequestBuildPolicy) return false
   79     86   
        if (scopeConfiguration != other.scopeConfiguration) return false
   80     87   
   81     88   
        return true
   82     89   
    }
   83     90   
   84     91   
    public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.codebuild.model.CreateWebhookRequest = Builder(this).apply(block).build()
   85     92   
   86     93   
    @SdkDsl
   87     94   
    public class Builder {
   88     95   
        /**
   89     96   
         * A regular expression used to determine which repository branches are built when a webhook is triggered. If the name of a branch matches the regular expression, then it is built. If `branchFilter` is empty, then all branches are built.
   90     97   
         *
   91     98   
         * It is recommended that you use `filterGroups` instead of `branchFilter`.
   92     99   
         */
   93    100   
        public var branchFilter: kotlin.String? = null
   94    101   
        /**
   95    102   
         * Specifies the type of build this webhook will trigger.
   96    103   
         *
   97    104   
         * `RUNNER_BUILDKITE_BUILD` is only available for `NO_SOURCE` source type projects configured for Buildkite runner builds. For more information about CodeBuild-hosted Buildkite runner builds, see [Tutorial: Configure a CodeBuild-hosted Buildkite runner](https://docs.aws.amazon.com/codebuild/latest/userguide/sample-runner-buildkite.html) in the *CodeBuild user guide*.
   98    105   
         */
   99    106   
        public var buildType: aws.sdk.kotlin.services.codebuild.model.WebhookBuildType? = null
  100    107   
        /**
  101    108   
         * An array of arrays of `WebhookFilter` objects used to determine which webhooks are triggered. At least one `WebhookFilter` in the array must specify `EVENT` as its `type`.
  102    109   
         *
  103    110   
         * For a build to be triggered, at least one filter group in the `filterGroups` array must pass. For a filter group to pass, each of its filters must pass.
  104    111   
         */
  105    112   
        public var filterGroups: List<List<WebhookFilter>>? = null
  106    113   
        /**
  107    114   
         * If manualCreation is true, CodeBuild doesn't create a webhook in GitHub and instead returns `payloadUrl` and `secret` values for the webhook. The `payloadUrl` and `secret` values in the output can be used to manually create a webhook within GitHub.
  108    115   
         *
  109    116   
         * `manualCreation` is only available for GitHub webhooks.
  110    117   
         */
  111    118   
        public var manualCreation: kotlin.Boolean? = null
  112    119   
        /**
  113    120   
         * The name of the CodeBuild project.
  114    121   
         */
  115    122   
        public var projectName: kotlin.String? = null
         123  +
        /**
         124  +
         * A PullRequestBuildPolicy object that defines comment-based approval requirements for triggering builds on pull requests. This policy helps control when automated builds are executed based on contributor permissions and approval workflows.
         125  +
         */
         126  +
        public var pullRequestBuildPolicy: aws.sdk.kotlin.services.codebuild.model.PullRequestBuildPolicy? = null
  116    127   
        /**
  117    128   
         * The scope configuration for global or organization webhooks.
  118    129   
         *
  119    130   
         * Global or organization webhooks are only available for GitHub and Github Enterprise webhooks.
  120    131   
         */
  121    132   
        public var scopeConfiguration: aws.sdk.kotlin.services.codebuild.model.ScopeConfiguration? = null
  122    133   
  123    134   
        @PublishedApi
  124    135   
        internal constructor()
  125    136   
        @PublishedApi
  126    137   
        internal constructor(x: aws.sdk.kotlin.services.codebuild.model.CreateWebhookRequest) : this() {
  127    138   
            this.branchFilter = x.branchFilter
  128    139   
            this.buildType = x.buildType
  129    140   
            this.filterGroups = x.filterGroups
  130    141   
            this.manualCreation = x.manualCreation
  131    142   
            this.projectName = x.projectName
         143  +
            this.pullRequestBuildPolicy = x.pullRequestBuildPolicy
  132    144   
            this.scopeConfiguration = x.scopeConfiguration
  133    145   
        }
  134    146   
  135    147   
        @PublishedApi
  136    148   
        internal fun build(): aws.sdk.kotlin.services.codebuild.model.CreateWebhookRequest = CreateWebhookRequest(this)
  137    149   
         150  +
        /**
         151  +
         * construct an [aws.sdk.kotlin.services.codebuild.model.PullRequestBuildPolicy] inside the given [block]
         152  +
         */
         153  +
        public fun pullRequestBuildPolicy(block: aws.sdk.kotlin.services.codebuild.model.PullRequestBuildPolicy.Builder.() -> kotlin.Unit) {
         154  +
            this.pullRequestBuildPolicy = aws.sdk.kotlin.services.codebuild.model.PullRequestBuildPolicy.invoke(block)
         155  +
        }
         156  +
  138    157   
        /**
  139    158   
         * construct an [aws.sdk.kotlin.services.codebuild.model.ScopeConfiguration] inside the given [block]
  140    159   
         */
  141    160   
        public fun scopeConfiguration(block: aws.sdk.kotlin.services.codebuild.model.ScopeConfiguration.Builder.() -> kotlin.Unit) {
  142    161   
            this.scopeConfiguration = aws.sdk.kotlin.services.codebuild.model.ScopeConfiguration.invoke(block)
  143    162   
        }
  144    163   
  145    164   
        internal fun correctErrors(): Builder {
  146    165   
            return this
  147    166   
        }

tmp-codegen-diff/services/codebuild/generated-src/main/kotlin/aws/sdk/kotlin/services/codebuild/model/StartBuildRequest.kt

@@ -1,1 +55,55 @@
   15     15   
    public val autoRetryLimitOverride: kotlin.Int? = builder.autoRetryLimitOverride
   16     16   
    /**
   17     17   
     * Contains information that defines how the build project reports the build status to the source provider. This option is only used when the source provider is `GITHUB`, `GITHUB_ENTERPRISE`, or `BITBUCKET`.
   18     18   
     */
   19     19   
    public val buildStatusConfigOverride: aws.sdk.kotlin.services.codebuild.model.BuildStatusConfig? = builder.buildStatusConfigOverride
   20     20   
    /**
   21     21   
     * A buildspec file declaration that overrides the latest one defined in the build project, for this build only. The buildspec defined on the project is not changed.
   22     22   
     *
   23     23   
     * If this value is set, it can be either an inline buildspec definition, the path to an alternate buildspec file relative to the value of the built-in `CODEBUILD_SRC_DIR` environment variable, or the path to an S3 bucket. The bucket must be in the same Amazon Web Services Region as the build project. Specify the buildspec file using its ARN (for example, `arn:aws:s3:::my-codebuild-sample2/buildspec.yml`). If this value is not provided or is set to an empty string, the source code must contain a buildspec file in its root directory. For more information, see [Buildspec File Name and Storage Location](https://docs.aws.amazon.com/codebuild/latest/userguide/build-spec-ref.html#build-spec-ref-name-storage).
   24     24   
     *
   25         -
     * Since this property allows you to change the build commands that will run in the container, you should note that an IAM principal with the ability to call this API and set this parameter can override the default settings. Moreover, we encourage that you use a trustworthy buildspec location like a file in your source repository or a Amazon S3 bucket.
          25  +
     * Since this property allows you to change the build commands that will run in the container, you should note that an IAM principal with the ability to call this API and set this parameter can override the default settings. Moreover, we encourage that you use a trustworthy buildspec location like a file in your source repository or a Amazon S3 bucket. Alternatively, you can restrict overrides to the buildspec by using a condition key: [Prevent unauthorized modifications to project buildspec](https://docs.aws.amazon.com/codebuild/latest/userguide/action-context-keys.html#action-context-keys-example-overridebuildspec.html).
   26     26   
     */
   27     27   
    public val buildspecOverride: kotlin.String? = builder.buildspecOverride
   28     28   
    /**
   29     29   
     * A ProjectCache object specified for this build that overrides the one defined in the build project.
   30     30   
     */
   31     31   
    public val cacheOverride: aws.sdk.kotlin.services.codebuild.model.ProjectCache? = builder.cacheOverride
   32     32   
    /**
   33     33   
     * The name of a certificate for this build that overrides the one specified in the build project.
   34     34   
     */
   35     35   
    public val certificateOverride: kotlin.String? = builder.certificateOverride
@@ -293,293 +353,353 @@
  313    313   
        public var autoRetryLimitOverride: kotlin.Int? = null
  314    314   
        /**
  315    315   
         * Contains information that defines how the build project reports the build status to the source provider. This option is only used when the source provider is `GITHUB`, `GITHUB_ENTERPRISE`, or `BITBUCKET`.
  316    316   
         */
  317    317   
        public var buildStatusConfigOverride: aws.sdk.kotlin.services.codebuild.model.BuildStatusConfig? = null
  318    318   
        /**
  319    319   
         * A buildspec file declaration that overrides the latest one defined in the build project, for this build only. The buildspec defined on the project is not changed.
  320    320   
         *
  321    321   
         * If this value is set, it can be either an inline buildspec definition, the path to an alternate buildspec file relative to the value of the built-in `CODEBUILD_SRC_DIR` environment variable, or the path to an S3 bucket. The bucket must be in the same Amazon Web Services Region as the build project. Specify the buildspec file using its ARN (for example, `arn:aws:s3:::my-codebuild-sample2/buildspec.yml`). If this value is not provided or is set to an empty string, the source code must contain a buildspec file in its root directory. For more information, see [Buildspec File Name and Storage Location](https://docs.aws.amazon.com/codebuild/latest/userguide/build-spec-ref.html#build-spec-ref-name-storage).
  322    322   
         *
  323         -
         * Since this property allows you to change the build commands that will run in the container, you should note that an IAM principal with the ability to call this API and set this parameter can override the default settings. Moreover, we encourage that you use a trustworthy buildspec location like a file in your source repository or a Amazon S3 bucket.
         323  +
         * Since this property allows you to change the build commands that will run in the container, you should note that an IAM principal with the ability to call this API and set this parameter can override the default settings. Moreover, we encourage that you use a trustworthy buildspec location like a file in your source repository or a Amazon S3 bucket. Alternatively, you can restrict overrides to the buildspec by using a condition key: [Prevent unauthorized modifications to project buildspec](https://docs.aws.amazon.com/codebuild/latest/userguide/action-context-keys.html#action-context-keys-example-overridebuildspec.html).
  324    324   
         */
  325    325   
        public var buildspecOverride: kotlin.String? = null
  326    326   
        /**
  327    327   
         * A ProjectCache object specified for this build that overrides the one defined in the build project.
  328    328   
         */
  329    329   
        public var cacheOverride: aws.sdk.kotlin.services.codebuild.model.ProjectCache? = null
  330    330   
        /**
  331    331   
         * The name of a certificate for this build that overrides the one specified in the build project.
  332    332   
         */
  333    333   
        public var certificateOverride: kotlin.String? = null

tmp-codegen-diff/services/codebuild/generated-src/main/kotlin/aws/sdk/kotlin/services/codebuild/model/UpdateWebhookRequest.kt

@@ -1,1 +118,137 @@
   18     18   
     */
   19     19   
    public val buildType: aws.sdk.kotlin.services.codebuild.model.WebhookBuildType? = builder.buildType
   20     20   
    /**
   21     21   
     * An array of arrays of `WebhookFilter` objects used to determine if a webhook event can trigger a build. A filter group must contain at least one `EVENT``WebhookFilter`.
   22     22   
     */
   23     23   
    public val filterGroups: List<List<WebhookFilter>>? = builder.filterGroups
   24     24   
    /**
   25     25   
     * The name of the CodeBuild project.
   26     26   
     */
   27     27   
    public val projectName: kotlin.String? = builder.projectName
          28  +
    /**
          29  +
     * A PullRequestBuildPolicy object that defines comment-based approval requirements for triggering builds on pull requests. This policy helps control when automated builds are executed based on contributor permissions and approval workflows.
          30  +
     */
          31  +
    public val pullRequestBuildPolicy: aws.sdk.kotlin.services.codebuild.model.PullRequestBuildPolicy? = builder.pullRequestBuildPolicy
   28     32   
    /**
   29     33   
     * A boolean value that specifies whether the associated GitHub repository's secret token should be updated. If you use Bitbucket for your repository, `rotateSecret` is ignored.
   30     34   
     */
   31     35   
    public val rotateSecret: kotlin.Boolean? = builder.rotateSecret
   32     36   
   33     37   
    public companion object {
   34     38   
        public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.codebuild.model.UpdateWebhookRequest = Builder().apply(block).build()
   35     39   
    }
   36     40   
   37     41   
    override fun toString(): kotlin.String = buildString {
   38     42   
        append("UpdateWebhookRequest(")
   39     43   
        append("branchFilter=$branchFilter,")
   40     44   
        append("buildType=$buildType,")
   41     45   
        append("filterGroups=$filterGroups,")
   42     46   
        append("projectName=$projectName,")
          47  +
        append("pullRequestBuildPolicy=$pullRequestBuildPolicy,")
   43     48   
        append("rotateSecret=$rotateSecret")
   44     49   
        append(")")
   45     50   
    }
   46     51   
   47     52   
    override fun hashCode(): kotlin.Int {
   48     53   
        var result = branchFilter?.hashCode() ?: 0
   49     54   
        result = 31 * result + (this.buildType?.hashCode() ?: 0)
   50     55   
        result = 31 * result + (this.filterGroups?.hashCode() ?: 0)
   51     56   
        result = 31 * result + (this.projectName?.hashCode() ?: 0)
          57  +
        result = 31 * result + (this.pullRequestBuildPolicy?.hashCode() ?: 0)
   52     58   
        result = 31 * result + (this.rotateSecret?.hashCode() ?: 0)
   53     59   
        return result
   54     60   
    }
   55     61   
   56     62   
    override fun equals(other: kotlin.Any?): kotlin.Boolean {
   57     63   
        if (this === other) return true
   58     64   
        if (other == null || this::class != other::class) return false
   59     65   
   60     66   
        other as UpdateWebhookRequest
   61     67   
   62     68   
        if (branchFilter != other.branchFilter) return false
   63     69   
        if (buildType != other.buildType) return false
   64     70   
        if (filterGroups != other.filterGroups) return false
   65     71   
        if (projectName != other.projectName) return false
          72  +
        if (pullRequestBuildPolicy != other.pullRequestBuildPolicy) return false
   66     73   
        if (rotateSecret != other.rotateSecret) return false
   67     74   
   68     75   
        return true
   69     76   
    }
   70     77   
   71     78   
    public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.codebuild.model.UpdateWebhookRequest = Builder(this).apply(block).build()
   72     79   
   73     80   
    @SdkDsl
   74     81   
    public class Builder {
   75     82   
        /**
   76     83   
         * A regular expression used to determine which repository branches are built when a webhook is triggered. If the name of a branch matches the regular expression, then it is built. If `branchFilter` is empty, then all branches are built.
   77     84   
         *
   78     85   
         *  It is recommended that you use `filterGroups` instead of `branchFilter`.
   79     86   
         */
   80     87   
        public var branchFilter: kotlin.String? = null
   81     88   
        /**
   82     89   
         * Specifies the type of build this webhook will trigger.
   83     90   
         *
   84     91   
         * `RUNNER_BUILDKITE_BUILD` is only available for `NO_SOURCE` source type projects configured for Buildkite runner builds. For more information about CodeBuild-hosted Buildkite runner builds, see [Tutorial: Configure a CodeBuild-hosted Buildkite runner](https://docs.aws.amazon.com/codebuild/latest/userguide/sample-runner-buildkite.html) in the *CodeBuild user guide*.
   85     92   
         */
   86     93   
        public var buildType: aws.sdk.kotlin.services.codebuild.model.WebhookBuildType? = null
   87     94   
        /**
   88     95   
         * An array of arrays of `WebhookFilter` objects used to determine if a webhook event can trigger a build. A filter group must contain at least one `EVENT``WebhookFilter`.
   89     96   
         */
   90     97   
        public var filterGroups: List<List<WebhookFilter>>? = null
   91     98   
        /**
   92     99   
         * The name of the CodeBuild project.
   93    100   
         */
   94    101   
        public var projectName: kotlin.String? = null
         102  +
        /**
         103  +
         * A PullRequestBuildPolicy object that defines comment-based approval requirements for triggering builds on pull requests. This policy helps control when automated builds are executed based on contributor permissions and approval workflows.
         104  +
         */
         105  +
        public var pullRequestBuildPolicy: aws.sdk.kotlin.services.codebuild.model.PullRequestBuildPolicy? = null
   95    106   
        /**
   96    107   
         * A boolean value that specifies whether the associated GitHub repository's secret token should be updated. If you use Bitbucket for your repository, `rotateSecret` is ignored.
   97    108   
         */
   98    109   
        public var rotateSecret: kotlin.Boolean? = null
   99    110   
  100    111   
        @PublishedApi
  101    112   
        internal constructor()
  102    113   
        @PublishedApi
  103    114   
        internal constructor(x: aws.sdk.kotlin.services.codebuild.model.UpdateWebhookRequest) : this() {
  104    115   
            this.branchFilter = x.branchFilter
  105    116   
            this.buildType = x.buildType
  106    117   
            this.filterGroups = x.filterGroups
  107    118   
            this.projectName = x.projectName
         119  +
            this.pullRequestBuildPolicy = x.pullRequestBuildPolicy
  108    120   
            this.rotateSecret = x.rotateSecret
  109    121   
        }
  110    122   
  111    123   
        @PublishedApi
  112    124   
        internal fun build(): aws.sdk.kotlin.services.codebuild.model.UpdateWebhookRequest = UpdateWebhookRequest(this)
  113    125   
         126  +
        /**
         127  +
         * construct an [aws.sdk.kotlin.services.codebuild.model.PullRequestBuildPolicy] inside the given [block]
         128  +
         */
         129  +
        public fun pullRequestBuildPolicy(block: aws.sdk.kotlin.services.codebuild.model.PullRequestBuildPolicy.Builder.() -> kotlin.Unit) {
         130  +
            this.pullRequestBuildPolicy = aws.sdk.kotlin.services.codebuild.model.PullRequestBuildPolicy.invoke(block)
         131  +
        }
         132  +
  114    133   
        internal fun correctErrors(): Builder {
  115    134   
            return this
  116    135   
        }
  117    136   
    }
  118    137   
}

tmp-codegen-diff/services/codebuild/generated-src/main/kotlin/aws/sdk/kotlin/services/codebuild/model/Webhook.kt

@@ -14,14 +225,244 @@
   34     34   
    /**
   35     35   
     * If manualCreation is true, CodeBuild doesn't create a webhook in GitHub and instead returns `payloadUrl` and `secret` values for the webhook. The `payloadUrl` and `secret` values in the output can be used to manually create a webhook within GitHub.
   36     36   
     *
   37     37   
     * manualCreation is only available for GitHub webhooks.
   38     38   
     */
   39     39   
    public val manualCreation: kotlin.Boolean? = builder.manualCreation
   40     40   
    /**
   41     41   
     * The CodeBuild endpoint where webhook events are sent.
   42     42   
     */
   43     43   
    public val payloadUrl: kotlin.String? = builder.payloadUrl
          44  +
    /**
          45  +
     * A PullRequestBuildPolicy object that defines comment-based approval requirements for triggering builds on pull requests. This policy helps control when automated builds are executed based on contributor permissions and approval workflows.
          46  +
     */
          47  +
    public val pullRequestBuildPolicy: aws.sdk.kotlin.services.codebuild.model.PullRequestBuildPolicy? = builder.pullRequestBuildPolicy
   44     48   
    /**
   45     49   
     * The scope configuration for global or organization webhooks.
   46     50   
     *
   47     51   
     * Global or organization webhooks are only available for GitHub and Github Enterprise webhooks.
   48     52   
     */
   49     53   
    public val scopeConfiguration: aws.sdk.kotlin.services.codebuild.model.ScopeConfiguration? = builder.scopeConfiguration
   50     54   
    /**
   51     55   
     * The secret token of the associated repository.
   52     56   
     *
   53     57   
     * A Bitbucket webhook does not support `secret`.
   54     58   
     */
   55     59   
    public val secret: kotlin.String? = builder.secret
   56     60   
    /**
   57     61   
     * The status of the webhook. Valid values include:
   58     62   
     * + `CREATING`: The webhook is being created.
   59     63   
     * + `CREATE_FAILED`: The webhook has failed to create.
   60     64   
     * + `ACTIVE`: The webhook has succeeded and is active.
   61     65   
     * + `DELETING`: The webhook is being deleted.
   62     66   
     */
   63     67   
    public val status: aws.sdk.kotlin.services.codebuild.model.WebhookStatus? = builder.status
   64     68   
    /**
   65     69   
     * A message associated with the status of a webhook.
   66     70   
     */
   67     71   
    public val statusMessage: kotlin.String? = builder.statusMessage
   68     72   
    /**
   69     73   
     * The URL to the webhook.
   70     74   
     */
   71     75   
    public val url: kotlin.String? = builder.url
   72     76   
   73     77   
    public companion object {
   74     78   
        public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.codebuild.model.Webhook = Builder().apply(block).build()
   75     79   
    }
   76     80   
   77     81   
    override fun toString(): kotlin.String = buildString {
   78     82   
        append("Webhook(")
   79     83   
        append("branchFilter=$branchFilter,")
   80     84   
        append("buildType=$buildType,")
   81     85   
        append("filterGroups=$filterGroups,")
   82     86   
        append("lastModifiedSecret=$lastModifiedSecret,")
   83     87   
        append("manualCreation=$manualCreation,")
   84     88   
        append("payloadUrl=$payloadUrl,")
          89  +
        append("pullRequestBuildPolicy=$pullRequestBuildPolicy,")
   85     90   
        append("scopeConfiguration=$scopeConfiguration,")
   86     91   
        append("secret=$secret,")
   87     92   
        append("status=$status,")
   88     93   
        append("statusMessage=$statusMessage,")
   89     94   
        append("url=$url")
   90     95   
        append(")")
   91     96   
    }
   92     97   
   93     98   
    override fun hashCode(): kotlin.Int {
   94     99   
        var result = branchFilter?.hashCode() ?: 0
   95    100   
        result = 31 * result + (this.buildType?.hashCode() ?: 0)
   96    101   
        result = 31 * result + (this.filterGroups?.hashCode() ?: 0)
   97    102   
        result = 31 * result + (this.lastModifiedSecret?.hashCode() ?: 0)
   98    103   
        result = 31 * result + (this.manualCreation?.hashCode() ?: 0)
   99    104   
        result = 31 * result + (this.payloadUrl?.hashCode() ?: 0)
         105  +
        result = 31 * result + (this.pullRequestBuildPolicy?.hashCode() ?: 0)
  100    106   
        result = 31 * result + (this.scopeConfiguration?.hashCode() ?: 0)
  101    107   
        result = 31 * result + (this.secret?.hashCode() ?: 0)
  102    108   
        result = 31 * result + (this.status?.hashCode() ?: 0)
  103    109   
        result = 31 * result + (this.statusMessage?.hashCode() ?: 0)
  104    110   
        result = 31 * result + (this.url?.hashCode() ?: 0)
  105    111   
        return result
  106    112   
    }
  107    113   
  108    114   
    override fun equals(other: kotlin.Any?): kotlin.Boolean {
  109    115   
        if (this === other) return true
  110    116   
        if (other == null || this::class != other::class) return false
  111    117   
  112    118   
        other as Webhook
  113    119   
  114    120   
        if (branchFilter != other.branchFilter) return false
  115    121   
        if (buildType != other.buildType) return false
  116    122   
        if (filterGroups != other.filterGroups) return false
  117    123   
        if (lastModifiedSecret != other.lastModifiedSecret) return false
  118    124   
        if (manualCreation != other.manualCreation) return false
  119    125   
        if (payloadUrl != other.payloadUrl) return false
         126  +
        if (pullRequestBuildPolicy != other.pullRequestBuildPolicy) return false
  120    127   
        if (scopeConfiguration != other.scopeConfiguration) return false
  121    128   
        if (secret != other.secret) return false
  122    129   
        if (status != other.status) return false
  123    130   
        if (statusMessage != other.statusMessage) return false
  124    131   
        if (url != other.url) return false
  125    132   
  126    133   
        return true
  127    134   
    }
  128    135   
  129    136   
    public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.codebuild.model.Webhook = Builder(this).apply(block).build()
  130    137   
  131    138   
    @SdkDsl
  132    139   
    public class Builder {
  133    140   
        /**
  134    141   
         * A regular expression used to determine which repository branches are built when a webhook is triggered. If the name of a branch matches the regular expression, then it is built. If `branchFilter` is empty, then all branches are built.
  135    142   
         *
  136    143   
         * It is recommended that you use `filterGroups` instead of `branchFilter`.
  137    144   
         */
  138    145   
        public var branchFilter: kotlin.String? = null
  139    146   
        /**
  140    147   
         * Specifies the type of build this webhook will trigger.
  141    148   
         *
  142    149   
         * `RUNNER_BUILDKITE_BUILD` is only available for `NO_SOURCE` source type projects configured for Buildkite runner builds. For more information about CodeBuild-hosted Buildkite runner builds, see [Tutorial: Configure a CodeBuild-hosted Buildkite runner](https://docs.aws.amazon.com/codebuild/latest/userguide/sample-runner-buildkite.html) in the *CodeBuild user guide*.
  143    150   
         */
  144    151   
        public var buildType: aws.sdk.kotlin.services.codebuild.model.WebhookBuildType? = null
  145    152   
        /**
  146    153   
         * An array of arrays of `WebhookFilter` objects used to determine which webhooks are triggered. At least one `WebhookFilter` in the array must specify `EVENT` as its `type`.
  147    154   
         *
  148    155   
         * For a build to be triggered, at least one filter group in the `filterGroups` array must pass. For a filter group to pass, each of its filters must pass.
  149    156   
         */
  150    157   
        public var filterGroups: List<List<WebhookFilter>>? = null
  151    158   
        /**
  152    159   
         * A timestamp that indicates the last time a repository's secret token was modified.
  153    160   
         */
  154    161   
        public var lastModifiedSecret: aws.smithy.kotlin.runtime.time.Instant? = null
  155    162   
        /**
  156    163   
         * If manualCreation is true, CodeBuild doesn't create a webhook in GitHub and instead returns `payloadUrl` and `secret` values for the webhook. The `payloadUrl` and `secret` values in the output can be used to manually create a webhook within GitHub.
  157    164   
         *
  158    165   
         * manualCreation is only available for GitHub webhooks.
  159    166   
         */
  160    167   
        public var manualCreation: kotlin.Boolean? = null
  161    168   
        /**
  162    169   
         * The CodeBuild endpoint where webhook events are sent.
  163    170   
         */
  164    171   
        public var payloadUrl: kotlin.String? = null
         172  +
        /**
         173  +
         * A PullRequestBuildPolicy object that defines comment-based approval requirements for triggering builds on pull requests. This policy helps control when automated builds are executed based on contributor permissions and approval workflows.
         174  +
         */
         175  +
        public var pullRequestBuildPolicy: aws.sdk.kotlin.services.codebuild.model.PullRequestBuildPolicy? = null
  165    176   
        /**
  166    177   
         * The scope configuration for global or organization webhooks.
  167    178   
         *
  168    179   
         * Global or organization webhooks are only available for GitHub and Github Enterprise webhooks.
  169    180   
         */
  170    181   
        public var scopeConfiguration: aws.sdk.kotlin.services.codebuild.model.ScopeConfiguration? = null
  171    182   
        /**
  172    183   
         * The secret token of the associated repository.
  173    184   
         *
  174    185   
         * A Bitbucket webhook does not support `secret`.
  175    186   
         */
  176    187   
        public var secret: kotlin.String? = null
  177    188   
        /**
  178    189   
         * The status of the webhook. Valid values include:
  179    190   
         * + `CREATING`: The webhook is being created.
  180    191   
         * + `CREATE_FAILED`: The webhook has failed to create.
  181    192   
         * + `ACTIVE`: The webhook has succeeded and is active.
  182    193   
         * + `DELETING`: The webhook is being deleted.
  183    194   
         */
  184    195   
        public var status: aws.sdk.kotlin.services.codebuild.model.WebhookStatus? = null
  185    196   
        /**
  186    197   
         * A message associated with the status of a webhook.
  187    198   
         */
  188    199   
        public var statusMessage: kotlin.String? = null
  189    200   
        /**
  190    201   
         * The URL to the webhook.
  191    202   
         */
  192    203   
        public var url: kotlin.String? = null
  193    204   
  194    205   
        @PublishedApi
  195    206   
        internal constructor()
  196    207   
        @PublishedApi
  197    208   
        internal constructor(x: aws.sdk.kotlin.services.codebuild.model.Webhook) : this() {
  198    209   
            this.branchFilter = x.branchFilter
  199    210   
            this.buildType = x.buildType
  200    211   
            this.filterGroups = x.filterGroups
  201    212   
            this.lastModifiedSecret = x.lastModifiedSecret
  202    213   
            this.manualCreation = x.manualCreation
  203    214   
            this.payloadUrl = x.payloadUrl
         215  +
            this.pullRequestBuildPolicy = x.pullRequestBuildPolicy
  204    216   
            this.scopeConfiguration = x.scopeConfiguration
  205    217   
            this.secret = x.secret
  206    218   
            this.status = x.status
  207    219   
            this.statusMessage = x.statusMessage
  208    220   
            this.url = x.url
  209    221   
        }
  210    222   
  211    223   
        @PublishedApi
  212    224   
        internal fun build(): aws.sdk.kotlin.services.codebuild.model.Webhook = Webhook(this)
  213    225   
         226  +
        /**
         227  +
         * construct an [aws.sdk.kotlin.services.codebuild.model.PullRequestBuildPolicy] inside the given [block]
         228  +
         */
         229  +
        public fun pullRequestBuildPolicy(block: aws.sdk.kotlin.services.codebuild.model.PullRequestBuildPolicy.Builder.() -> kotlin.Unit) {
         230  +
            this.pullRequestBuildPolicy = aws.sdk.kotlin.services.codebuild.model.PullRequestBuildPolicy.invoke(block)
         231  +
        }
         232  +
  214    233   
        /**
  215    234   
         * construct an [aws.sdk.kotlin.services.codebuild.model.ScopeConfiguration] inside the given [block]
  216    235   
         */
  217    236   
        public fun scopeConfiguration(block: aws.sdk.kotlin.services.codebuild.model.ScopeConfiguration.Builder.() -> kotlin.Unit) {
  218    237   
            this.scopeConfiguration = aws.sdk.kotlin.services.codebuild.model.ScopeConfiguration.invoke(block)
  219    238   
        }
  220    239   
  221    240   
        internal fun correctErrors(): Builder {
  222    241   
            return this
  223    242   
        }

tmp-codegen-diff/services/codebuild/generated-src/main/kotlin/aws/sdk/kotlin/services/codebuild/serde/CreateWebhookOperationSerializer.kt

@@ -1,1 +86,90 @@
    1      1   
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
    2      2   
    3      3   
package aws.sdk.kotlin.services.codebuild.serde
    4      4   
    5      5   
import aws.sdk.kotlin.services.codebuild.model.CreateWebhookRequest
           6  +
import aws.sdk.kotlin.services.codebuild.model.PullRequestBuildPolicy
    6      7   
import aws.sdk.kotlin.services.codebuild.model.ScopeConfiguration
    7      8   
import aws.sdk.kotlin.services.codebuild.model.WebhookBuildType
    8      9   
import aws.sdk.kotlin.services.codebuild.model.WebhookFilter
    9     10   
import aws.smithy.kotlin.runtime.http.HttpBody
   10     11   
import aws.smithy.kotlin.runtime.http.HttpMethod
   11     12   
import aws.smithy.kotlin.runtime.http.operation.HttpSerializer
   12     13   
import aws.smithy.kotlin.runtime.http.request.HttpRequestBuilder
   13     14   
import aws.smithy.kotlin.runtime.http.request.url
   14     15   
import aws.smithy.kotlin.runtime.operation.ExecutionContext
   15     16   
import aws.smithy.kotlin.runtime.serde.SdkFieldDescriptor
   16     17   
import aws.smithy.kotlin.runtime.serde.SdkObjectDescriptor
   17     18   
import aws.smithy.kotlin.runtime.serde.SerialKind
   18     19   
import aws.smithy.kotlin.runtime.serde.asSdkSerializable
   19     20   
import aws.smithy.kotlin.runtime.serde.deserializeList
   20     21   
import aws.smithy.kotlin.runtime.serde.deserializeMap
   21     22   
import aws.smithy.kotlin.runtime.serde.deserializeStruct
   22     23   
import aws.smithy.kotlin.runtime.serde.field
   23     24   
import aws.smithy.kotlin.runtime.serde.json.JsonDeserializer
   24     25   
import aws.smithy.kotlin.runtime.serde.json.JsonSerialName
   25     26   
import aws.smithy.kotlin.runtime.serde.json.JsonSerializer
   26     27   
import aws.smithy.kotlin.runtime.serde.serializeList
   27     28   
import aws.smithy.kotlin.runtime.serde.serializeMap
   28     29   
import aws.smithy.kotlin.runtime.serde.serializeStruct
   29     30   
   30     31   
   31     32   
internal class CreateWebhookOperationSerializer: HttpSerializer.NonStreaming<CreateWebhookRequest> {
   32     33   
    override fun serialize(context: ExecutionContext, input: CreateWebhookRequest): HttpRequestBuilder {
   33     34   
        val builder = HttpRequestBuilder()
   34     35   
        builder.method = HttpMethod.POST
   35     36   
   36     37   
        builder.url {
   37     38   
            path.encoded = "/"
   38     39   
        }
   39     40   
   40     41   
        val payload = serializeCreateWebhookOperationBody(context, input)
   41     42   
        builder.body = HttpBody.fromBytes(payload)
   42     43   
        if (builder.body !is HttpBody.Empty) {
   43     44   
            builder.headers.setMissing("Content-Type", "application/x-amz-json-1.1")
   44     45   
        }
   45     46   
        return builder
   46     47   
    }
   47     48   
}
   48     49   
   49     50   
private fun serializeCreateWebhookOperationBody(context: ExecutionContext, input: CreateWebhookRequest): ByteArray {
   50     51   
    val serializer = JsonSerializer()
   51     52   
    val BRANCHFILTER_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("branchFilter"))
   52     53   
    val BUILDTYPE_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Enum, JsonSerialName("buildType"))
   53     54   
    val FILTERGROUPS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.List, JsonSerialName("filterGroups"))
   54     55   
    val FILTERGROUPS_C0_DESCRIPTOR = SdkFieldDescriptor(SerialKind.List)
   55     56   
    val MANUALCREATION_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Boolean, JsonSerialName("manualCreation"))
   56     57   
    val PROJECTNAME_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("projectName"))
          58  +
    val PULLREQUESTBUILDPOLICY_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Struct, JsonSerialName("pullRequestBuildPolicy"))
   57     59   
    val SCOPECONFIGURATION_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Struct, JsonSerialName("scopeConfiguration"))
   58     60   
    val OBJ_DESCRIPTOR = SdkObjectDescriptor.build {
   59     61   
        field(BRANCHFILTER_DESCRIPTOR)
   60     62   
        field(BUILDTYPE_DESCRIPTOR)
   61     63   
        field(FILTERGROUPS_DESCRIPTOR)
   62     64   
        field(MANUALCREATION_DESCRIPTOR)
   63     65   
        field(PROJECTNAME_DESCRIPTOR)
          66  +
        field(PULLREQUESTBUILDPOLICY_DESCRIPTOR)
   64     67   
        field(SCOPECONFIGURATION_DESCRIPTOR)
   65     68   
    }
   66     69   
   67     70   
    serializer.serializeStruct(OBJ_DESCRIPTOR) {
   68     71   
        input.branchFilter?.let { field(BRANCHFILTER_DESCRIPTOR, it) }
   69     72   
        input.buildType?.let { field(BUILDTYPE_DESCRIPTOR, it.value) }
   70     73   
        if (input.filterGroups != null) {
   71     74   
            listField(FILTERGROUPS_DESCRIPTOR) {
   72     75   
                for (el0 in input.filterGroups) {
   73     76   
                    serializer.serializeList(FILTERGROUPS_C0_DESCRIPTOR) {
   74     77   
                        for (el1 in el0) {
   75     78   
                            serializeSdkSerializable(asSdkSerializable(el1, ::serializeWebhookFilterDocument))
   76     79   
                        }
   77     80   
                    }
   78     81   
                }
   79     82   
            }
   80     83   
        }
   81     84   
        input.manualCreation?.let { field(MANUALCREATION_DESCRIPTOR, it) }
   82     85   
        input.projectName?.let { field(PROJECTNAME_DESCRIPTOR, it) }
          86  +
        input.pullRequestBuildPolicy?.let { field(PULLREQUESTBUILDPOLICY_DESCRIPTOR, it, ::serializePullRequestBuildPolicyDocument) }
   83     87   
        input.scopeConfiguration?.let { field(SCOPECONFIGURATION_DESCRIPTOR, it, ::serializeScopeConfigurationDocument) }
   84     88   
    }
   85     89   
    return serializer.toByteArray()
   86     90   
}

tmp-codegen-diff/services/codebuild/generated-src/main/kotlin/aws/sdk/kotlin/services/codebuild/serde/UpdateWebhookOperationSerializer.kt

@@ -1,1 +82,86 @@
    1      1   
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
    2      2   
    3      3   
package aws.sdk.kotlin.services.codebuild.serde
    4      4   
           5  +
import aws.sdk.kotlin.services.codebuild.model.PullRequestBuildPolicy
    5      6   
import aws.sdk.kotlin.services.codebuild.model.UpdateWebhookRequest
    6      7   
import aws.sdk.kotlin.services.codebuild.model.WebhookBuildType
    7      8   
import aws.sdk.kotlin.services.codebuild.model.WebhookFilter
    8      9   
import aws.smithy.kotlin.runtime.http.HttpBody
    9     10   
import aws.smithy.kotlin.runtime.http.HttpMethod
   10     11   
import aws.smithy.kotlin.runtime.http.operation.HttpSerializer
   11     12   
import aws.smithy.kotlin.runtime.http.request.HttpRequestBuilder
   12     13   
import aws.smithy.kotlin.runtime.http.request.url
   13     14   
import aws.smithy.kotlin.runtime.operation.ExecutionContext
   14     15   
import aws.smithy.kotlin.runtime.serde.SdkFieldDescriptor
   15     16   
import aws.smithy.kotlin.runtime.serde.SdkObjectDescriptor
   16     17   
import aws.smithy.kotlin.runtime.serde.SerialKind
   17     18   
import aws.smithy.kotlin.runtime.serde.asSdkSerializable
   18     19   
import aws.smithy.kotlin.runtime.serde.deserializeList
   19     20   
import aws.smithy.kotlin.runtime.serde.deserializeMap
   20     21   
import aws.smithy.kotlin.runtime.serde.deserializeStruct
   21     22   
import aws.smithy.kotlin.runtime.serde.field
   22     23   
import aws.smithy.kotlin.runtime.serde.json.JsonDeserializer
   23     24   
import aws.smithy.kotlin.runtime.serde.json.JsonSerialName
   24     25   
import aws.smithy.kotlin.runtime.serde.json.JsonSerializer
   25     26   
import aws.smithy.kotlin.runtime.serde.serializeList
   26     27   
import aws.smithy.kotlin.runtime.serde.serializeMap
   27     28   
import aws.smithy.kotlin.runtime.serde.serializeStruct
   28     29   
   29     30   
   30     31   
internal class UpdateWebhookOperationSerializer: HttpSerializer.NonStreaming<UpdateWebhookRequest> {
   31     32   
    override fun serialize(context: ExecutionContext, input: UpdateWebhookRequest): HttpRequestBuilder {
   32     33   
        val builder = HttpRequestBuilder()
   33     34   
        builder.method = HttpMethod.POST
   34     35   
   35     36   
        builder.url {
   36     37   
            path.encoded = "/"
   37     38   
        }
   38     39   
   39     40   
        val payload = serializeUpdateWebhookOperationBody(context, input)
   40     41   
        builder.body = HttpBody.fromBytes(payload)
   41     42   
        if (builder.body !is HttpBody.Empty) {
   42     43   
            builder.headers.setMissing("Content-Type", "application/x-amz-json-1.1")
   43     44   
        }
   44     45   
        return builder
   45     46   
    }
   46     47   
}
   47     48   
   48     49   
private fun serializeUpdateWebhookOperationBody(context: ExecutionContext, input: UpdateWebhookRequest): ByteArray {
   49     50   
    val serializer = JsonSerializer()
   50     51   
    val BRANCHFILTER_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("branchFilter"))
   51     52   
    val BUILDTYPE_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Enum, JsonSerialName("buildType"))
   52     53   
    val FILTERGROUPS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.List, JsonSerialName("filterGroups"))
   53     54   
    val FILTERGROUPS_C0_DESCRIPTOR = SdkFieldDescriptor(SerialKind.List)
   54     55   
    val PROJECTNAME_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("projectName"))
          56  +
    val PULLREQUESTBUILDPOLICY_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Struct, JsonSerialName("pullRequestBuildPolicy"))
   55     57   
    val ROTATESECRET_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Boolean, JsonSerialName("rotateSecret"))
   56     58   
    val OBJ_DESCRIPTOR = SdkObjectDescriptor.build {
   57     59   
        field(BRANCHFILTER_DESCRIPTOR)
   58     60   
        field(BUILDTYPE_DESCRIPTOR)
   59     61   
        field(FILTERGROUPS_DESCRIPTOR)
   60     62   
        field(PROJECTNAME_DESCRIPTOR)
          63  +
        field(PULLREQUESTBUILDPOLICY_DESCRIPTOR)
   61     64   
        field(ROTATESECRET_DESCRIPTOR)
   62     65   
    }
   63     66   
   64     67   
    serializer.serializeStruct(OBJ_DESCRIPTOR) {
   65     68   
        input.branchFilter?.let { field(BRANCHFILTER_DESCRIPTOR, it) }
   66     69   
        input.buildType?.let { field(BUILDTYPE_DESCRIPTOR, it.value) }
   67     70   
        if (input.filterGroups != null) {
   68     71   
            listField(FILTERGROUPS_DESCRIPTOR) {
   69     72   
                for (el0 in input.filterGroups) {
   70     73   
                    serializer.serializeList(FILTERGROUPS_C0_DESCRIPTOR) {
   71     74   
                        for (el1 in el0) {
   72     75   
                            serializeSdkSerializable(asSdkSerializable(el1, ::serializeWebhookFilterDocument))
   73     76   
                        }
   74     77   
                    }
   75     78   
                }
   76     79   
            }
   77     80   
        }
   78     81   
        input.projectName?.let { field(PROJECTNAME_DESCRIPTOR, it) }
          82  +
        input.pullRequestBuildPolicy?.let { field(PULLREQUESTBUILDPOLICY_DESCRIPTOR, it, ::serializePullRequestBuildPolicyDocument) }
   79     83   
        input.rotateSecret?.let { field(ROTATESECRET_DESCRIPTOR, it) }
   80     84   
    }
   81     85   
    return serializer.toByteArray()
   82     86   
}

tmp-codegen-diff/services/codebuild/generated-src/main/kotlin/aws/sdk/kotlin/services/codebuild/serde/WebhookDocumentDeserializer.kt

@@ -6,6 +91,94 @@
   26     26   
   27     27   
internal fun deserializeWebhookDocument(deserializer: Deserializer): Webhook {
   28     28   
    val builder = Webhook.Builder()
   29     29   
    val BRANCHFILTER_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("branchFilter"))
   30     30   
    val BUILDTYPE_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Enum, JsonSerialName("buildType"))
   31     31   
    val FILTERGROUPS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.List, JsonSerialName("filterGroups"))
   32     32   
    val FILTERGROUPS_C0_DESCRIPTOR = SdkFieldDescriptor(SerialKind.List)
   33     33   
    val LASTMODIFIEDSECRET_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Timestamp, JsonSerialName("lastModifiedSecret"))
   34     34   
    val MANUALCREATION_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Boolean, JsonSerialName("manualCreation"))
   35     35   
    val PAYLOADURL_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("payloadUrl"))
          36  +
    val PULLREQUESTBUILDPOLICY_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Struct, JsonSerialName("pullRequestBuildPolicy"))
   36     37   
    val SCOPECONFIGURATION_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Struct, JsonSerialName("scopeConfiguration"))
   37     38   
    val SECRET_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("secret"))
   38     39   
    val STATUS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Enum, JsonSerialName("status"))
   39     40   
    val STATUSMESSAGE_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("statusMessage"))
   40     41   
    val URL_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("url"))
   41     42   
    val OBJ_DESCRIPTOR = SdkObjectDescriptor.build {
   42     43   
        field(BRANCHFILTER_DESCRIPTOR)
   43     44   
        field(BUILDTYPE_DESCRIPTOR)
   44     45   
        field(FILTERGROUPS_DESCRIPTOR)
   45     46   
        field(LASTMODIFIEDSECRET_DESCRIPTOR)
   46     47   
        field(MANUALCREATION_DESCRIPTOR)
   47     48   
        field(PAYLOADURL_DESCRIPTOR)
          49  +
        field(PULLREQUESTBUILDPOLICY_DESCRIPTOR)
   48     50   
        field(SCOPECONFIGURATION_DESCRIPTOR)
   49     51   
        field(SECRET_DESCRIPTOR)
   50     52   
        field(STATUS_DESCRIPTOR)
   51     53   
        field(STATUSMESSAGE_DESCRIPTOR)
   52     54   
        field(URL_DESCRIPTOR)
   53     55   
    }
   54     56   
   55     57   
    deserializer.deserializeStruct(OBJ_DESCRIPTOR) {
   56     58   
        loop@while (true) {
   57     59   
            when (findNextFieldIndex()) {
   58     60   
                BRANCHFILTER_DESCRIPTOR.index -> builder.branchFilter = deserializeString()
   59     61   
                BUILDTYPE_DESCRIPTOR.index -> builder.buildType = deserializeString().let { WebhookBuildType.fromValue(it) }
   60     62   
                FILTERGROUPS_DESCRIPTOR.index -> builder.filterGroups =
   61     63   
                    deserializer.deserializeList(FILTERGROUPS_DESCRIPTOR) {
   62     64   
                        val col0 = mutableListOf<List<WebhookFilter>>()
   63     65   
                        while (hasNextElement()) {
   64     66   
                            val el0 = deserializer.deserializeList(FILTERGROUPS_C0_DESCRIPTOR) {
   65     67   
                                val col1 = mutableListOf<WebhookFilter>()
   66     68   
                                while (hasNextElement()) {
   67     69   
                                    val el1 = if (nextHasValue()) { deserializeWebhookFilterDocument(deserializer) } else { deserializeNull(); continue }
   68     70   
                                    col1.add(el1)
   69     71   
                                }
   70     72   
                                col1
   71     73   
                            }
   72     74   
                            col0.add(el0)
   73     75   
                        }
   74     76   
                        col0
   75     77   
                    }
   76     78   
                LASTMODIFIEDSECRET_DESCRIPTOR.index -> builder.lastModifiedSecret = deserializeInstant(TimestampFormat.EPOCH_SECONDS)
   77     79   
                MANUALCREATION_DESCRIPTOR.index -> builder.manualCreation = deserializeBoolean()
   78     80   
                PAYLOADURL_DESCRIPTOR.index -> builder.payloadUrl = deserializeString()
          81  +
                PULLREQUESTBUILDPOLICY_DESCRIPTOR.index -> builder.pullRequestBuildPolicy = deserializePullRequestBuildPolicyDocument(deserializer)
   79     82   
                SCOPECONFIGURATION_DESCRIPTOR.index -> builder.scopeConfiguration = deserializeScopeConfigurationDocument(deserializer)
   80     83   
                SECRET_DESCRIPTOR.index -> builder.secret = deserializeString()
   81     84   
                STATUS_DESCRIPTOR.index -> builder.status = deserializeString().let { WebhookStatus.fromValue(it) }
   82     85   
                STATUSMESSAGE_DESCRIPTOR.index -> builder.statusMessage = deserializeString()
   83     86   
                URL_DESCRIPTOR.index -> builder.url = deserializeString()
   84     87   
                null -> break@loop
   85     88   
                else -> skipValue()
   86     89   
            }
   87     90   
        }
   88     91   
    }

tmp-codegen-diff/services/codebuild/generated-src/test/kotlin/aws/sdk/kotlin/services/codebuild/endpoints/DefaultEndpointProviderTest.kt

@@ -580,580 +798,742 @@
  600    600   
            useFips = false
  601    601   
            useDualStack = true
  602    602   
        }
  603    603   
        val expected = Endpoint(
  604    604   
            uri = Url.parse("https://codebuild.us-gov-east-1.api.aws"),
  605    605   
        )
  606    606   
        val actual = DefaultCodeBuildEndpointProvider().resolveEndpoint(params)
  607    607   
        expectEqualEndpoints(expected, actual)
  608    608   
    }
  609    609   
  610         -
    // For region us-iso-east-1 with FIPS enabled and DualStack enabled
  611         -
    @Test
  612         -
    fun test39() = runTest {
  613         -
        val params = CodeBuildEndpointParameters {
  614         -
            region = "us-iso-east-1"
  615         -
            useFips = true
  616         -
            useDualStack = true
  617         -
        }
  618         -
        val ex = assertFailsWith<EndpointProviderException> {
  619         -
            DefaultCodeBuildEndpointProvider().resolveEndpoint(params)
  620         -
        }
  621         -
        assertEquals("FIPS and DualStack are enabled, but this partition does not support one or both", ex.message)
  622         -
    }
  623         -
  624    610   
    // For region us-iso-east-1 with FIPS enabled and DualStack disabled
  625    611   
    @Test
  626         -
    fun test40() = runTest {
         612  +
    fun test39() = runTest {
  627    613   
        val params = CodeBuildEndpointParameters {
  628    614   
            region = "us-iso-east-1"
  629    615   
            useFips = true
  630    616   
            useDualStack = false
  631    617   
        }
  632    618   
        val expected = Endpoint(
  633    619   
            uri = Url.parse("https://codebuild-fips.us-iso-east-1.c2s.ic.gov"),
  634    620   
        )
  635    621   
        val actual = DefaultCodeBuildEndpointProvider().resolveEndpoint(params)
  636    622   
        expectEqualEndpoints(expected, actual)
  637    623   
    }
  638    624   
  639         -
    // For region us-iso-east-1 with FIPS disabled and DualStack enabled
  640         -
    @Test
  641         -
    fun test41() = runTest {
  642         -
        val params = CodeBuildEndpointParameters {
  643         -
            region = "us-iso-east-1"
  644         -
            useFips = false
  645         -
            useDualStack = true
  646         -
        }
  647         -
        val ex = assertFailsWith<EndpointProviderException> {
  648         -
            DefaultCodeBuildEndpointProvider().resolveEndpoint(params)
  649         -
        }
  650         -
        assertEquals("DualStack is enabled but this partition does not support DualStack", ex.message)
  651         -
    }
  652         -
  653    625   
    // For region us-iso-east-1 with FIPS disabled and DualStack disabled
  654    626   
    @Test
  655         -
    fun test42() = runTest {
         627  +
    fun test40() = runTest {
  656    628   
        val params = CodeBuildEndpointParameters {
  657    629   
            region = "us-iso-east-1"
  658    630   
            useFips = false
  659    631   
            useDualStack = false
  660    632   
        }
  661    633   
        val expected = Endpoint(
  662    634   
            uri = Url.parse("https://codebuild.us-iso-east-1.c2s.ic.gov"),
  663    635   
        )
  664    636   
        val actual = DefaultCodeBuildEndpointProvider().resolveEndpoint(params)
  665    637   
        expectEqualEndpoints(expected, actual)
  666    638   
    }
  667    639   
  668         -
    // For region us-isob-east-1 with FIPS enabled and DualStack enabled
  669         -
    @Test
  670         -
    fun test43() = runTest {
  671         -
        val params = CodeBuildEndpointParameters {
  672         -
            region = "us-isob-east-1"
  673         -
            useFips = true
  674         -
            useDualStack = true
  675         -
        }
  676         -
        val ex = assertFailsWith<EndpointProviderException> {
  677         -
            DefaultCodeBuildEndpointProvider().resolveEndpoint(params)
  678         -
        }
  679         -
        assertEquals("FIPS and DualStack are enabled, but this partition does not support one or both", ex.message)
  680         -
    }
  681         -
  682    640   
    // For region us-isob-east-1 with FIPS enabled and DualStack disabled
  683    641   
    @Test
  684         -
    fun test44() = runTest {
         642  +
    fun test41() = runTest {
  685    643   
        val params = CodeBuildEndpointParameters {
  686    644   
            region = "us-isob-east-1"
  687    645   
            useFips = true
  688    646   
            useDualStack = false
  689    647   
        }
  690    648   
        val expected = Endpoint(
  691    649   
            uri = Url.parse("https://codebuild-fips.us-isob-east-1.sc2s.sgov.gov"),
  692    650   
        )
  693    651   
        val actual = DefaultCodeBuildEndpointProvider().resolveEndpoint(params)
  694    652   
        expectEqualEndpoints(expected, actual)
  695    653   
    }
  696    654   
  697         -
    // For region us-isob-east-1 with FIPS disabled and DualStack enabled
  698         -
    @Test
  699         -
    fun test45() = runTest {
  700         -
        val params = CodeBuildEndpointParameters {
  701         -
            region = "us-isob-east-1"
  702         -
            useFips = false
  703         -
            useDualStack = true
  704         -
        }
  705         -
        val ex = assertFailsWith<EndpointProviderException> {
  706         -
            DefaultCodeBuildEndpointProvider().resolveEndpoint(params)
  707         -
        }
  708         -
        assertEquals("DualStack is enabled but this partition does not support DualStack", ex.message)
  709         -
    }
  710         -
  711    655   
    // For region us-isob-east-1 with FIPS disabled and DualStack disabled
  712    656   
    @Test
  713         -
    fun test46() = runTest {
         657  +
    fun test42() = runTest {
  714    658   
        val params = CodeBuildEndpointParameters {
  715    659   
            region = "us-isob-east-1"
  716    660   
            useFips = false
  717    661   
            useDualStack = false
  718    662   
        }
  719    663   
        val expected = Endpoint(
  720    664   
            uri = Url.parse("https://codebuild.us-isob-east-1.sc2s.sgov.gov"),
  721    665   
        )
  722    666   
        val actual = DefaultCodeBuildEndpointProvider().resolveEndpoint(params)
  723    667   
        expectEqualEndpoints(expected, actual)
  724    668   
    }
  725    669   
  726    670   
    // For custom endpoint with region set and fips disabled and dualstack disabled
  727    671   
    @Test
  728         -
    fun test47() = runTest {
         672  +
    fun test43() = runTest {
  729    673   
        val params = CodeBuildEndpointParameters {
  730    674   
            region = "us-east-1"
  731    675   
            useFips = false
  732    676   
            useDualStack = false
  733    677   
            endpoint = "https://example.com"
  734    678   
        }
  735    679   
        val expected = Endpoint(
  736    680   
            uri = Url.parse("https://example.com"),
  737    681   
        )
  738    682   
        val actual = DefaultCodeBuildEndpointProvider().resolveEndpoint(params)
  739    683   
        expectEqualEndpoints(expected, actual)
  740    684   
    }
  741    685   
  742    686   
    // For custom endpoint with region not set and fips disabled and dualstack disabled
  743    687   
    @Test
  744         -
    fun test48() = runTest {
         688  +
    fun test44() = runTest {
  745    689   
        val params = CodeBuildEndpointParameters {
  746    690   
            useFips = false
  747    691   
            useDualStack = false
  748    692   
            endpoint = "https://example.com"
  749    693   
        }
  750    694   
        val expected = Endpoint(
  751    695   
            uri = Url.parse("https://example.com"),
  752    696   
        )
  753    697   
        val actual = DefaultCodeBuildEndpointProvider().resolveEndpoint(params)
  754    698   
        expectEqualEndpoints(expected, actual)
  755    699   
    }
  756    700   
  757    701   
    // For custom endpoint with fips enabled and dualstack disabled
  758    702   
    @Test
  759         -
    fun test49() = runTest {
         703  +
    fun test45() = runTest {
  760    704   
        val params = CodeBuildEndpointParameters {
  761    705   
            region = "us-east-1"
  762    706   
            useFips = true
  763    707   
            useDualStack = false
  764    708   
            endpoint = "https://example.com"
  765    709   
        }
  766    710   
        val ex = assertFailsWith<EndpointProviderException> {
  767    711   
            DefaultCodeBuildEndpointProvider().resolveEndpoint(params)
  768    712   
        }
  769    713   
        assertEquals("Invalid Configuration: FIPS and custom endpoint are not supported", ex.message)
  770    714   
    }
  771    715   
  772    716   
    // For custom endpoint with fips disabled and dualstack enabled
  773    717   
    @Test
  774         -
    fun test50() = runTest {
         718  +
    fun test46() = runTest {
  775    719   
        val params = CodeBuildEndpointParameters {
  776    720   
            region = "us-east-1"
  777    721   
            useFips = false
  778    722   
            useDualStack = true
  779    723   
            endpoint = "https://example.com"
  780    724   
        }
  781    725   
        val ex = assertFailsWith<EndpointProviderException> {
  782    726   
            DefaultCodeBuildEndpointProvider().resolveEndpoint(params)
  783    727   
        }
  784    728   
        assertEquals("Invalid Configuration: Dualstack and custom endpoint are not supported", ex.message)
  785    729   
    }
  786    730   
  787    731   
    // Missing region
  788    732   
    @Test
  789         -
    fun test51() = runTest {
         733  +
    fun test47() = runTest {
  790    734   
        val params = CodeBuildEndpointParameters {
  791    735   
        }
  792    736   
        val ex = assertFailsWith<EndpointProviderException> {
  793    737   
            DefaultCodeBuildEndpointProvider().resolveEndpoint(params)
  794    738   
        }
  795    739   
        assertEquals("Invalid Configuration: Missing Region", ex.message)
  796    740   
    }
  797    741   
  798    742   
}

tmp-codegen-diff/services/dynamodb/generated-src/main/kotlin/aws/sdk/kotlin/services/dynamodb/DynamoDbClient.kt

@@ -146,146 +206,206 @@
  166    166   
import aws.smithy.kotlin.runtime.telemetry.TelemetryConfig
  167    167   
import aws.smithy.kotlin.runtime.telemetry.TelemetryProvider
  168    168   
import aws.smithy.kotlin.runtime.util.LazyAsyncValue
  169    169   
import kotlin.collections.List
  170    170   
import kotlin.jvm.JvmStatic
  171    171   
import kotlin.time.Duration
  172    172   
import kotlinx.coroutines.runBlocking
  173    173   
  174    174   
  175    175   
public const val ServiceId: String = "DynamoDB"
  176         -
public const val SdkVersion: String = "1.5.12-SNAPSHOT"
         176  +
public const val SdkVersion: String = "1.5.53-SNAPSHOT"
  177    177   
public const val ServiceApiVersion: String = "2012-08-10"
  178    178   
  179    179   
/**
  180    180   
 * # Amazon DynamoDB
  181    181   
 * Amazon DynamoDB is a fully managed NoSQL database service that provides fast and predictable performance with seamless scalability. DynamoDB lets you offload the administrative burdens of operating and scaling a distributed database, so that you don't have to worry about hardware provisioning, setup and configuration, replication, software patching, or cluster scaling.
  182    182   
 *
  183    183   
 * With DynamoDB, you can create database tables that can store and retrieve any amount of data, and serve any level of request traffic. You can scale up or scale down your tables' throughput capacity without downtime or performance degradation, and use the Amazon Web Services Management Console to monitor resource utilization and performance metrics.
  184    184   
 *
  185    185   
 * DynamoDB automatically spreads the data and traffic for your tables over a sufficient number of servers to handle your throughput and storage requirements, while maintaining consistent and fast performance. All of your data is stored on solid state disks (SSDs) and automatically replicated across multiple Availability Zones in an Amazon Web Services Region, providing built-in high availability and data durability.
  186    186   
 */

tmp-codegen-diff/services/dynamodb/generated-src/main/kotlin/aws/sdk/kotlin/services/dynamodb/endpoints/internal/Partitions.kt

@@ -14,14 +73,75 @@
   34     34   
            "ap-southeast-1" to PartitionConfig(
   35     35   
            ),
   36     36   
            "ap-southeast-2" to PartitionConfig(
   37     37   
            ),
   38     38   
            "ap-southeast-3" to PartitionConfig(
   39     39   
            ),
   40     40   
            "ap-southeast-4" to PartitionConfig(
   41     41   
            ),
   42     42   
            "ap-southeast-5" to PartitionConfig(
   43     43   
            ),
          44  +
            "ap-southeast-6" to PartitionConfig(
          45  +
            ),
   44     46   
            "ap-southeast-7" to PartitionConfig(
   45     47   
            ),
   46     48   
            "aws-global" to PartitionConfig(
   47     49   
            ),
   48     50   
            "ca-central-1" to PartitionConfig(
   49     51   
            ),
   50     52   
            "ca-west-1" to PartitionConfig(
   51     53   
            ),
   52     54   
            "eu-central-1" to PartitionConfig(
   53     55   
            ),
@@ -87,89 +228,230 @@
  107    109   
        baseConfig = PartitionConfig(
  108    110   
            name = "aws-cn",
  109    111   
            dnsSuffix = "amazonaws.com.cn",
  110    112   
            dualStackDnsSuffix = "api.amazonwebservices.com.cn",
  111    113   
            supportsFIPS = true,
  112    114   
            supportsDualStack = true,
  113    115   
            implicitGlobalRegion = "cn-northwest-1",
  114    116   
        ),
  115    117   
    ),
  116    118   
    Partition(
  117         -
        id = "aws-us-gov",
  118         -
        regionRegex = Regex("^us\\-gov\\-\\w+\\-\\d+$"),
         119  +
        id = "aws-eusc",
         120  +
        regionRegex = Regex("^eusc\\-(de)\\-\\w+\\-\\d+$"),
  119    121   
        regions = mapOf(
  120         -
            "aws-us-gov-global" to PartitionConfig(
  121         -
            ),
  122         -
            "us-gov-east-1" to PartitionConfig(
  123         -
            ),
  124         -
            "us-gov-west-1" to PartitionConfig(
         122  +
            "eusc-de-east-1" to PartitionConfig(
  125    123   
            ),
  126    124   
        ),
  127    125   
        baseConfig = PartitionConfig(
  128         -
            name = "aws-us-gov",
  129         -
            dnsSuffix = "amazonaws.com",
  130         -
            dualStackDnsSuffix = "api.aws",
         126  +
            name = "aws-eusc",
         127  +
            dnsSuffix = "amazonaws.eu",
         128  +
            dualStackDnsSuffix = "api.amazonwebservices.eu",
  131    129   
            supportsFIPS = true,
  132    130   
            supportsDualStack = true,
  133         -
            implicitGlobalRegion = "us-gov-west-1",
         131  +
            implicitGlobalRegion = "eusc-de-east-1",
  134    132   
        ),
  135    133   
    ),
  136    134   
    Partition(
  137    135   
        id = "aws-iso",
  138    136   
        regionRegex = Regex("^us\\-iso\\-\\w+\\-\\d+$"),
  139    137   
        regions = mapOf(
  140    138   
            "aws-iso-global" to PartitionConfig(
  141    139   
            ),
  142    140   
            "us-iso-east-1" to PartitionConfig(
  143    141   
            ),
  144    142   
            "us-iso-west-1" to PartitionConfig(
  145    143   
            ),
  146    144   
        ),
  147    145   
        baseConfig = PartitionConfig(
  148    146   
            name = "aws-iso",
  149    147   
            dnsSuffix = "c2s.ic.gov",
  150         -
            dualStackDnsSuffix = "c2s.ic.gov",
         148  +
            dualStackDnsSuffix = "api.aws.ic.gov",
  151    149   
            supportsFIPS = true,
  152         -
            supportsDualStack = false,
         150  +
            supportsDualStack = true,
  153    151   
            implicitGlobalRegion = "us-iso-east-1",
  154    152   
        ),
  155    153   
    ),
  156    154   
    Partition(
  157    155   
        id = "aws-iso-b",
  158    156   
        regionRegex = Regex("^us\\-isob\\-\\w+\\-\\d+$"),
  159    157   
        regions = mapOf(
  160    158   
            "aws-iso-b-global" to PartitionConfig(
  161    159   
            ),
  162    160   
            "us-isob-east-1" to PartitionConfig(
  163    161   
            ),
  164    162   
        ),
  165    163   
        baseConfig = PartitionConfig(
  166    164   
            name = "aws-iso-b",
  167    165   
            dnsSuffix = "sc2s.sgov.gov",
  168         -
            dualStackDnsSuffix = "sc2s.sgov.gov",
         166  +
            dualStackDnsSuffix = "api.aws.scloud",
  169    167   
            supportsFIPS = true,
  170         -
            supportsDualStack = false,
         168  +
            supportsDualStack = true,
  171    169   
            implicitGlobalRegion = "us-isob-east-1",
  172    170   
        ),
  173    171   
    ),
  174    172   
    Partition(
  175    173   
        id = "aws-iso-e",
  176    174   
        regionRegex = Regex("^eu\\-isoe\\-\\w+\\-\\d+$"),
  177    175   
        regions = mapOf(
  178    176   
            "aws-iso-e-global" to PartitionConfig(
  179    177   
            ),
  180    178   
            "eu-isoe-west-1" to PartitionConfig(
  181    179   
            ),
  182    180   
        ),
  183    181   
        baseConfig = PartitionConfig(
  184    182   
            name = "aws-iso-e",
  185    183   
            dnsSuffix = "cloud.adc-e.uk",
  186         -
            dualStackDnsSuffix = "cloud.adc-e.uk",
         184  +
            dualStackDnsSuffix = "api.cloud-aws.adc-e.uk",
  187    185   
            supportsFIPS = true,
  188         -
            supportsDualStack = false,
         186  +
            supportsDualStack = true,
  189    187   
            implicitGlobalRegion = "eu-isoe-west-1",
  190    188   
        ),
  191    189   
    ),
  192    190   
    Partition(
  193    191   
        id = "aws-iso-f",
  194    192   
        regionRegex = Regex("^us\\-isof\\-\\w+\\-\\d+$"),
  195    193   
        regions = mapOf(
  196    194   
            "aws-iso-f-global" to PartitionConfig(
  197    195   
            ),
  198    196   
            "us-isof-east-1" to PartitionConfig(
  199    197   
            ),
  200    198   
            "us-isof-south-1" to PartitionConfig(
  201    199   
            ),
  202    200   
        ),
  203    201   
        baseConfig = PartitionConfig(
  204    202   
            name = "aws-iso-f",
  205    203   
            dnsSuffix = "csp.hci.ic.gov",
  206         -
            dualStackDnsSuffix = "csp.hci.ic.gov",
         204  +
            dualStackDnsSuffix = "api.aws.hci.ic.gov",
  207    205   
            supportsFIPS = true,
  208         -
            supportsDualStack = false,
         206  +
            supportsDualStack = true,
  209    207   
            implicitGlobalRegion = "us-isof-south-1",
  210    208   
        ),
  211    209   
    ),
  212    210   
    Partition(
  213         -
        id = "aws-eusc",
  214         -
        regionRegex = Regex("^eusc\\-(de)\\-\\w+\\-\\d+$"),
         211  +
        id = "aws-us-gov",
         212  +
        regionRegex = Regex("^us\\-gov\\-\\w+\\-\\d+$"),
  215    213   
        regions = mapOf(
  216         -
            "eusc-de-east-1" to PartitionConfig(
         214  +
            "aws-us-gov-global" to PartitionConfig(
         215  +
            ),
         216  +
            "us-gov-east-1" to PartitionConfig(
         217  +
            ),
         218  +
            "us-gov-west-1" to PartitionConfig(
  217    219   
            ),
  218    220   
        ),
  219    221   
        baseConfig = PartitionConfig(
  220         -
            name = "aws-eusc",
  221         -
            dnsSuffix = "amazonaws.eu",
  222         -
            dualStackDnsSuffix = "amazonaws.eu",
         222  +
            name = "aws-us-gov",
         223  +
            dnsSuffix = "amazonaws.com",
         224  +
            dualStackDnsSuffix = "api.aws",
  223    225   
            supportsFIPS = true,
  224         -
            supportsDualStack = false,
  225         -
            implicitGlobalRegion = "eusc-de-east-1",
         226  +
            supportsDualStack = true,
         227  +
            implicitGlobalRegion = "us-gov-west-1",
  226    228   
        ),
  227    229   
    ),
  228    230   
)

tmp-codegen-diff/services/dynamodb/generated-src/main/kotlin/aws/sdk/kotlin/services/dynamodb/model/ContributorInsightsSummary.kt

@@ -1,1 +89,101 @@
    1      1   
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
    2      2   
    3      3   
package aws.sdk.kotlin.services.dynamodb.model
    4      4   
    5      5   
import aws.smithy.kotlin.runtime.SdkDsl
    6      6   
    7      7   
/**
    8      8   
 * Represents a Contributor Insights summary entry.
    9      9   
 */
   10     10   
public class ContributorInsightsSummary private constructor(builder: Builder) {
          11  +
    /**
          12  +
     * Indicates the current mode of CloudWatch Contributor Insights, specifying whether it tracks all access and throttled events or throttled events only for the DynamoDB table or index.
          13  +
     */
          14  +
    public val contributorInsightsMode: aws.sdk.kotlin.services.dynamodb.model.ContributorInsightsMode? = builder.contributorInsightsMode
   11     15   
    /**
   12     16   
     * Describes the current status for contributor insights for the given table and index, if applicable.
   13     17   
     */
   14     18   
    public val contributorInsightsStatus: aws.sdk.kotlin.services.dynamodb.model.ContributorInsightsStatus? = builder.contributorInsightsStatus
   15     19   
    /**
   16     20   
     * Name of the index associated with the summary, if any.
   17     21   
     */
   18     22   
    public val indexName: kotlin.String? = builder.indexName
   19     23   
    /**
   20     24   
     * Name of the table associated with the summary.
   21     25   
     */
   22     26   
    public val tableName: kotlin.String? = builder.tableName
   23     27   
   24     28   
    public companion object {
   25     29   
        public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.dynamodb.model.ContributorInsightsSummary = Builder().apply(block).build()
   26     30   
    }
   27     31   
   28     32   
    override fun toString(): kotlin.String = buildString {
   29     33   
        append("ContributorInsightsSummary(")
          34  +
        append("contributorInsightsMode=$contributorInsightsMode,")
   30     35   
        append("contributorInsightsStatus=$contributorInsightsStatus,")
   31     36   
        append("indexName=$indexName,")
   32     37   
        append("tableName=$tableName")
   33     38   
        append(")")
   34     39   
    }
   35     40   
   36     41   
    override fun hashCode(): kotlin.Int {
   37         -
        var result = contributorInsightsStatus?.hashCode() ?: 0
          42  +
        var result = contributorInsightsMode?.hashCode() ?: 0
          43  +
        result = 31 * result + (this.contributorInsightsStatus?.hashCode() ?: 0)
   38     44   
        result = 31 * result + (this.indexName?.hashCode() ?: 0)
   39     45   
        result = 31 * result + (this.tableName?.hashCode() ?: 0)
   40     46   
        return result
   41     47   
    }
   42     48   
   43     49   
    override fun equals(other: kotlin.Any?): kotlin.Boolean {
   44     50   
        if (this === other) return true
   45     51   
        if (other == null || this::class != other::class) return false
   46     52   
   47     53   
        other as ContributorInsightsSummary
   48     54   
          55  +
        if (contributorInsightsMode != other.contributorInsightsMode) return false
   49     56   
        if (contributorInsightsStatus != other.contributorInsightsStatus) return false
   50     57   
        if (indexName != other.indexName) return false
   51     58   
        if (tableName != other.tableName) return false
   52     59   
   53     60   
        return true
   54     61   
    }
   55     62   
   56     63   
    public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.dynamodb.model.ContributorInsightsSummary = Builder(this).apply(block).build()
   57     64   
   58     65   
    @SdkDsl
   59     66   
    public class Builder {
          67  +
        /**
          68  +
         * Indicates the current mode of CloudWatch Contributor Insights, specifying whether it tracks all access and throttled events or throttled events only for the DynamoDB table or index.
          69  +
         */
          70  +
        public var contributorInsightsMode: aws.sdk.kotlin.services.dynamodb.model.ContributorInsightsMode? = null
   60     71   
        /**
   61     72   
         * Describes the current status for contributor insights for the given table and index, if applicable.
   62     73   
         */
   63     74   
        public var contributorInsightsStatus: aws.sdk.kotlin.services.dynamodb.model.ContributorInsightsStatus? = null
   64     75   
        /**
   65     76   
         * Name of the index associated with the summary, if any.
   66     77   
         */
   67     78   
        public var indexName: kotlin.String? = null
   68     79   
        /**
   69     80   
         * Name of the table associated with the summary.
   70     81   
         */
   71     82   
        public var tableName: kotlin.String? = null
   72     83   
   73     84   
        @PublishedApi
   74     85   
        internal constructor()
   75     86   
        @PublishedApi
   76     87   
        internal constructor(x: aws.sdk.kotlin.services.dynamodb.model.ContributorInsightsSummary) : this() {
          88  +
            this.contributorInsightsMode = x.contributorInsightsMode
   77     89   
            this.contributorInsightsStatus = x.contributorInsightsStatus
   78     90   
            this.indexName = x.indexName
   79     91   
            this.tableName = x.tableName
   80     92   
        }
   81     93   
   82     94   
        @PublishedApi
   83     95   
        internal fun build(): aws.sdk.kotlin.services.dynamodb.model.ContributorInsightsSummary = ContributorInsightsSummary(this)
   84     96   
   85     97   
        internal fun correctErrors(): Builder {
   86     98   
            return this