Skip to content

Commit b6d829b

Browse files
committed
updated build number
1 parent a88afcd commit b6d829b

22 files changed

Lines changed: 29 additions & 30 deletions

kotlin/services/comprehend/build.gradle.kts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
22

33
plugins {
4-
kotlin("jvm") version "1.9.0"
4+
kotlin("jvm") version "2.0.0"
55
application
66
}
77

@@ -29,7 +29,7 @@ repositories {
2929
apply(plugin = "org.jlleitschuh.gradle.ktlint")
3030

3131
dependencies {
32-
implementation(platform("aws.sdk.kotlin:bom:1.3.112"))
32+
implementation(platform("aws.sdk.kotlin:bom:1.4.119"))
3333
implementation("aws.sdk.kotlin:comprehend")
3434
implementation("aws.sdk.kotlin:secretsmanager")
3535
implementation("aws.smithy.kotlin:http-client-engine-okhttp")

kotlin/services/comprehend/src/main/kotlin/com/kotlin/comprehend/DetectEntities.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ suspend fun detectAllEntities(textVal: String) {
3333
text = textVal
3434
languageCode = LanguageCode.fromValue("en")
3535
}
36-
ComprehendClient { region = "us-east-1" }.use { comClient ->
36+
ComprehendClient.fromEnvironment { region = "us-east-1" }.use { comClient ->
3737
val response = comClient.detectEntities(request)
3838
response.entities?.forEach { entity ->
3939
println("Entity text is ${entity.text}")

kotlin/services/comprehend/src/main/kotlin/com/kotlin/comprehend/DetectKeyPhrases.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ suspend fun detectAllKeyPhrases(textVal: String) {
3434
languageCode = LanguageCode.fromValue("en")
3535
}
3636

37-
ComprehendClient { region = "us-east-1" }.use { comClient ->
37+
ComprehendClient.fromEnvironment { region = "us-east-1" }.use { comClient ->
3838
val response = comClient.detectKeyPhrases(request)
3939
response.keyPhrases?.forEach { phrase ->
4040
println("Key phrase text is ${phrase.text}")

kotlin/services/comprehend/src/main/kotlin/com/kotlin/comprehend/DetectLanguage.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ suspend fun detectTheDominantLanguage(textVal: String) {
2020
text = textVal
2121
}
2222

23-
ComprehendClient { region = "us-east-1" }.use { comClient ->
23+
ComprehendClient.fromEnvironment { region = "us-east-1" }.use { comClient ->
2424
val response = comClient.detectDominantLanguage(request)
2525
response.languages?.forEach { lang ->
2626
println("Language is ${lang.languageCode}")

kotlin/services/comprehend/src/main/kotlin/com/kotlin/comprehend/DetectSentiment.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ suspend fun detectSentiments(textVal: String) {
3333
languageCode = LanguageCode.fromValue("en")
3434
}
3535

36-
ComprehendClient { region = "us-east-1" }.use { comClient ->
36+
ComprehendClient.fromEnvironment { region = "us-east-1" }.use { comClient ->
3737
val resp = comClient.detectSentiment(request)
3838
println("The Neutral value is ${resp.sentimentScore?.neutral}")
3939
}

kotlin/services/comprehend/src/main/kotlin/com/kotlin/comprehend/DetectSyntax.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ suspend fun detectAllSyntax(textVal: String) {
3333
text = textVal
3434
languageCode = SyntaxLanguageCode.fromValue("en")
3535
}
36-
ComprehendClient { region = "us-east-1" }.use { comClient ->
36+
ComprehendClient.fromEnvironment { region = "us-east-1" }.use { comClient ->
3737
val response = comClient.detectSyntax(request)
3838
response.syntaxTokens?.forEach { token ->
3939
println("Language is ${token.text}")

kotlin/services/comprehend/src/main/kotlin/com/kotlin/comprehend/DocumentClassifierDemo.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ suspend fun createDocumentClassifier(
6060
inputDataConfig = config
6161
}
6262

63-
ComprehendClient { region = "us-east-1" }.use { comClient ->
63+
ComprehendClient.fromEnvironment { region = "us-east-1" }.use { comClient ->
6464
val resp = comClient.createDocumentClassifier(request)
6565
val documentClassifierArn = resp.documentClassifierArn
6666
println("Document Classifier ARN is $documentClassifierArn")

kotlin/services/dynamodb/build.gradle.kts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
22

33
plugins {
4-
kotlin("jvm") version "1.9.0"
4+
kotlin("jvm") version "2.1.0"
55
application
66
}
77

@@ -27,7 +27,7 @@ repositories {
2727
}
2828
apply(plugin = "org.jlleitschuh.gradle.ktlint")
2929
dependencies {
30-
implementation(platform("aws.sdk.kotlin:bom:1.3.112"))
30+
implementation(platform("aws.sdk.kotlin:bom:1.4.119"))
3131
implementation("aws.sdk.kotlin:dynamodb")
3232
implementation("aws.sdk.kotlin:secretsmanager")
3333
implementation("aws.smithy.kotlin:http-client-engine-okhttp")

kotlin/services/dynamodb/src/main/kotlin/com/kotlin/dynamodb/CreateTable.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ suspend fun createNewTable(
7070
tableName = tableNameVal
7171
}
7272

73-
DynamoDbClient { region = "us-east-1" }.use { ddb ->
73+
DynamoDbClient.fromEnvironment { region = "us-east-1" }.use { ddb ->
7474
var tableArn: String
7575
val response = ddb.createTable(request)
7676
ddb.waitUntilTableExists {

kotlin/services/dynamodb/src/main/kotlin/com/kotlin/dynamodb/DeleteItem.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ suspend fun deleteDynamoDBItem(
5555
key = keyToGet
5656
}
5757

58-
DynamoDbClient { region = "us-east-1" }.use { ddb ->
58+
DynamoDbClient.fromEnvironment { region = "us-east-1" }.use { ddb ->
5959
ddb.deleteItem(request)
6060
println("Item with key matching $keyVal was deleted")
6161
}

0 commit comments

Comments
 (0)