Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions gradle.properties
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
smithyVersion=1.62.0
smithyGradleVersion=1.3.0
smithyPluginVersion=0.7.0
smithyGradleVersion=1.3.0
25 changes: 14 additions & 11 deletions smithy-typescript-protocol-test-codegen/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import software.amazon.smithy.gradle.tasks.SmithyBuild
import software.amazon.smithy.gradle.tasks.SmithyBuildTask

val smithyVersion: String by project

Expand All @@ -15,23 +15,26 @@ buildscript {
}

plugins {
val smithyPluginVersion: String by project
id("software.amazon.smithy").version(smithyPluginVersion)
`java-library`

val smithyGradleVersion: String by project
id("software.amazon.smithy.gradle.smithy-base").version(smithyGradleVersion)
}

dependencies {
implementation("software.amazon.smithy:smithy-protocol-tests:$smithyVersion")
implementation(project(":smithy-typescript-codegen"))
}

// This project doesn't produce a JAR.
tasks["jar"].enabled = false

tasks["smithyBuildJar"].enabled = false

tasks.register<SmithyBuild>("buildSdk") {
addRuntimeClasspath = true
val buildSdk = tasks.register<SmithyBuildTask>("buildSdk") {
models.set(files("model/"))
smithyBuildConfigs.set(files("smithy-build.json"))
}

// Run the `buildSdk` automatically.
tasks["build"].finalizedBy(tasks["buildSdk"])
tasks["build"].finalizedBy(buildSdk)

tasks.register<Sync>("copyOutput") {
into(layout.buildDirectory.dir("model"))
from(buildSdk.map { it.getPluginProjectionDirectory("source", "model") })
}
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ use smithy.protocols#rpcv2Cbor
@rpcv2Cbor
@documentation("xyz interfaces")
service XYZService {
version: "1.0",
operations : [
version: "1.0"
operations: [
GetNumbers
]
}
Expand All @@ -18,9 +18,9 @@ operation GetNumbers {
input: GetNumbersRequest
output: GetNumbersResponse
errors: [
CodedThrottlingError,
MysteryThrottlingError,
RetryableError,
CodedThrottlingError
MysteryThrottlingError
RetryableError
HaltError
]
}
Expand All @@ -47,8 +47,8 @@ structure CodedThrottlingError {}
structure MysteryThrottlingError {}

@error("client")
@retryable()
@retryable
structure RetryableError {}

@error("client")
structure HaltError {}
structure HaltError {}
Loading