From 2850dd5de18fd3b937028a84ed8e288038b8873d Mon Sep 17 00:00:00 2001 From: Dhawal Kapil Date: Wed, 28 Dec 2022 00:27:48 +0530 Subject: [PATCH] Task/java 16779 (#13211) * JAVA-16779 Removed kubernetes-spring from the kubernetes-modules - Removed kubernete-spring from the parent pom of kubernetes-modules since it is a JDK11 module * JAVA-16779 Converted KinesisApplicationIntegrationTest to ManualTest - Converted KinesisApplicationIntegrationTest to ManualTest since it needs working AWS credentials to work - Added missing properties --- .../src/main/resources/application.properties | 3 ++- ....java => KinesisApplicationManualTest.java} | 11 +++++++---- .../src/test/resources/application.properties | 18 +++++++++++++++++- 3 files changed, 26 insertions(+), 6 deletions(-) rename spring-cloud-modules/spring-cloud-stream/spring-cloud-stream-kinesis/src/test/java/com/baeldung/{KinesisApplicationIntegrationTest.java => KinesisApplicationManualTest.java} (53%) diff --git a/spring-cloud-modules/spring-cloud-stream/spring-cloud-stream-kinesis/src/main/resources/application.properties b/spring-cloud-modules/spring-cloud-stream/spring-cloud-stream-kinesis/src/main/resources/application.properties index cc1f321453..1943766c26 100644 --- a/spring-cloud-modules/spring-cloud-stream/spring-cloud-stream-kinesis/src/main/resources/application.properties +++ b/spring-cloud-modules/spring-cloud-stream/spring-cloud-stream-kinesis/src/main/resources/application.properties @@ -14,4 +14,5 @@ spring.cloud.stream.bindings.output.destination=myStream spring.cloud.stream.bindings.output.content-type=text/plain ips.partition.key=ips-partition-key -ips.stream=ips-stream \ No newline at end of file +ips.stream=ips-stream +ips.shard.id=1 \ No newline at end of file diff --git a/spring-cloud-modules/spring-cloud-stream/spring-cloud-stream-kinesis/src/test/java/com/baeldung/KinesisApplicationIntegrationTest.java b/spring-cloud-modules/spring-cloud-stream/spring-cloud-stream-kinesis/src/test/java/com/baeldung/KinesisApplicationManualTest.java similarity index 53% rename from spring-cloud-modules/spring-cloud-stream/spring-cloud-stream-kinesis/src/test/java/com/baeldung/KinesisApplicationIntegrationTest.java rename to spring-cloud-modules/spring-cloud-stream/spring-cloud-stream-kinesis/src/test/java/com/baeldung/KinesisApplicationManualTest.java index 4e1c281cfb..a232d29be5 100644 --- a/spring-cloud-modules/spring-cloud-stream/spring-cloud-stream-kinesis/src/test/java/com/baeldung/KinesisApplicationIntegrationTest.java +++ b/spring-cloud-modules/spring-cloud-stream/spring-cloud-stream-kinesis/src/test/java/com/baeldung/KinesisApplicationManualTest.java @@ -5,11 +5,14 @@ import org.junit.runner.RunWith; import org.springframework.boot.test.context.SpringBootTest; import org.springframework.test.context.junit4.SpringRunner; +/** + * Manual Test - this test needs correct AWS Access Key and Secret to build the Amazon Kinesis and complete successfully + */ @RunWith(SpringRunner.class) @SpringBootTest(classes = KinesisApplication.class) -public class KinesisApplicationIntegrationTest { - @Test - public void whenSpringContextIsBootstrapped_thenNoExceptions() { +public class KinesisApplicationManualTest { + @Test + public void whenSpringContextIsBootstrapped_thenNoExceptions() { - } + } } \ No newline at end of file diff --git a/spring-cloud-modules/spring-cloud-stream/spring-cloud-stream-kinesis/src/test/resources/application.properties b/spring-cloud-modules/spring-cloud-stream/spring-cloud-stream-kinesis/src/test/resources/application.properties index 48005616ec..1943766c26 100644 --- a/spring-cloud-modules/spring-cloud-stream/spring-cloud-stream-kinesis/src/test/resources/application.properties +++ b/spring-cloud-modules/spring-cloud-stream/spring-cloud-stream-kinesis/src/test/resources/application.properties @@ -1,2 +1,18 @@ +aws.access.key=my-aws-access-key-goes-here +aws.secret.key=my-aws-secret-key-goes-here + +cloud.aws.credentials.access-key=my-aws-access-key +cloud.aws.credentials.secret-key=my-aws-secret-key cloud.aws.region.static=eu-central-1 -cloud.aws.stack.auto=false \ No newline at end of file +cloud.aws.stack.auto=false + +spring.cloud.stream.bindings.input.destination=live-ips +spring.cloud.stream.bindings.input.group=live-ips-group +spring.cloud.stream.bindings.input.content-type=text/plain + +spring.cloud.stream.bindings.output.destination=myStream +spring.cloud.stream.bindings.output.content-type=text/plain + +ips.partition.key=ips-partition-key +ips.stream=ips-stream +ips.shard.id=1 \ No newline at end of file