Skip to content

Commit 3dc3a56

Browse files
build(deps): bump aws-lambda-java-events from 3.11.1 to 3.11.2 (#1215)
* build(deps): bump aws-lambda-java-events from 3.11.1 to 3.11.2 * fix idempotency tests
1 parent 55626ce commit 3dc3a56

File tree

7 files changed

+20
-20
lines changed

7 files changed

+20
-20
lines changed

examples/powertools-examples-core/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
<dependency>
3636
<groupId>com.amazonaws</groupId>
3737
<artifactId>aws-lambda-java-events</artifactId>
38-
<version>3.11.1</version>
38+
<version>3.11.2</version>
3939
</dependency>
4040
<dependency>
4141
<groupId>org.apache.logging.log4j</groupId>

examples/powertools-examples-idempotency/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
<dependency>
3636
<groupId>com.amazonaws</groupId>
3737
<artifactId>aws-lambda-java-events</artifactId>
38-
<version>3.11.1</version>
38+
<version>3.11.2</version>
3939
</dependency>
4040
<dependency>
4141
<groupId>org.apache.logging.log4j</groupId>

examples/powertools-examples-parameters/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
<dependency>
3131
<groupId>com.amazonaws</groupId>
3232
<artifactId>aws-lambda-java-events</artifactId>
33-
<version>3.11.1</version>
33+
<version>3.11.2</version>
3434
</dependency>
3535

3636
<!-- Test dependencies -->

examples/powertools-examples-serialization/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
<dependency>
3131
<groupId>com.amazonaws</groupId>
3232
<artifactId>aws-lambda-java-events</artifactId>
33-
<version>3.11.1</version>
33+
<version>3.11.2</version>
3434
</dependency>
3535

3636
<!-- Test dependencies -->

examples/powertools-examples-sqs/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
<dependency>
3636
<groupId>com.amazonaws</groupId>
3737
<artifactId>aws-lambda-java-events</artifactId>
38-
<version>3.11.1</version>
38+
<version>3.11.2</version>
3939
</dependency>
4040
<dependency>
4141
<groupId>org.apache.logging.log4j</groupId>

pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@
6565
<payloadoffloading-common.version>2.1.3</payloadoffloading-common.version>
6666
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
6767
<lambda.core.version>1.2.2</lambda.core.version>
68-
<lambda.events.version>3.11.1</lambda.events.version>
68+
<lambda.events.version>3.11.2</lambda.events.version>
6969
<lambda.serial.version>1.1.2</lambda.serial.version>
7070
<maven-compiler-plugin.version>3.11.0</maven-compiler-plugin.version>
7171
<aspectj-maven-plugin.version>1.13.1</aspectj-maven-plugin.version>

powertools-idempotency/src/test/java/software/amazon/lambda/powertools/idempotency/persistence/BasePersistenceStoreTest.java

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ public void saveInProgress_defaultConfig() {
8888
assertThat(dr.getStatus()).isEqualTo(DataRecord.Status.INPROGRESS);
8989
assertThat(dr.getExpiryTimestamp()).isEqualTo(now.plus(3600, ChronoUnit.SECONDS).getEpochSecond());
9090
assertThat(dr.getResponseData()).isNull();
91-
assertThat(dr.getIdempotencyKey()).isEqualTo("testFunction#47261bd5b456f400f8d191cfb3a7482f");
91+
assertThat(dr.getIdempotencyKey()).isEqualTo("testFunction#7b40f56c086de5aa91dc467456329ed2");
9292
assertThat(dr.getPayloadHash()).isEqualTo("");
9393
assertThat(dr.getInProgressExpiryTimestamp()).isEmpty();
9494
assertThat(status).isEqualTo(1);
@@ -105,7 +105,7 @@ public void saveInProgress_withRemainingTime() {
105105
assertThat(dr.getStatus()).isEqualTo(DataRecord.Status.INPROGRESS);
106106
assertThat(dr.getExpiryTimestamp()).isEqualTo(now.plus(3600, ChronoUnit.SECONDS).getEpochSecond());
107107
assertThat(dr.getResponseData()).isNull();
108-
assertThat(dr.getIdempotencyKey()).isEqualTo("testFunction#47261bd5b456f400f8d191cfb3a7482f");
108+
assertThat(dr.getIdempotencyKey()).isEqualTo("testFunction#7b40f56c086de5aa91dc467456329ed2");
109109
assertThat(dr.getPayloadHash()).isEqualTo("");
110110
assertThat(dr.getInProgressExpiryTimestamp().orElse(-1)).isEqualTo(now.plus(lambdaTimeoutMs, ChronoUnit.MILLIS).toEpochMilli());
111111
assertThat(status).isEqualTo(1);
@@ -216,7 +216,7 @@ public void saveSuccess_shouldUpdateRecord() throws JsonProcessingException {
216216
assertThat(dr.getStatus()).isEqualTo(DataRecord.Status.COMPLETED);
217217
assertThat(dr.getExpiryTimestamp()).isEqualTo(now.plus(3600, ChronoUnit.SECONDS).getEpochSecond());
218218
assertThat(dr.getResponseData()).isEqualTo(JsonConfig.get().getObjectMapper().writeValueAsString(product));
219-
assertThat(dr.getIdempotencyKey()).isEqualTo("testFunction#47261bd5b456f400f8d191cfb3a7482f");
219+
assertThat(dr.getIdempotencyKey()).isEqualTo("testFunction#7b40f56c086de5aa91dc467456329ed2");
220220
assertThat(dr.getPayloadHash()).isEqualTo("");
221221
assertThat(status).isEqualTo(2);
222222
assertThat(cache).isEmpty();
@@ -235,11 +235,11 @@ public void saveSuccess_withCacheEnabled_shouldSaveInCache() throws JsonProcessi
235235

236236
assertThat(status).isEqualTo(2);
237237
assertThat(cache).hasSize(1);
238-
DataRecord record = cache.get("testFunction#47261bd5b456f400f8d191cfb3a7482f");
238+
DataRecord record = cache.get("testFunction#7b40f56c086de5aa91dc467456329ed2");
239239
assertThat(record.getStatus()).isEqualTo(DataRecord.Status.COMPLETED);
240240
assertThat(record.getExpiryTimestamp()).isEqualTo(now.plus(3600, ChronoUnit.SECONDS).getEpochSecond());
241241
assertThat(record.getResponseData()).isEqualTo(JsonConfig.get().getObjectMapper().writeValueAsString(product));
242-
assertThat(record.getIdempotencyKey()).isEqualTo("testFunction#47261bd5b456f400f8d191cfb3a7482f");
242+
assertThat(record.getIdempotencyKey()).isEqualTo("testFunction#7b40f56c086de5aa91dc467456329ed2");
243243
assertThat(record.getPayloadHash()).isEqualTo("");
244244
}
245245

@@ -257,7 +257,7 @@ public void getRecord_shouldReturnRecordFromPersistence() throws IdempotencyItem
257257

258258
Instant now = Instant.now();
259259
DataRecord record = persistenceStore.getRecord(JsonConfig.get().getObjectMapper().valueToTree(event), now);
260-
assertThat(record.getIdempotencyKey()).isEqualTo("testFunction.myfunc#47261bd5b456f400f8d191cfb3a7482f");
260+
assertThat(record.getIdempotencyKey()).isEqualTo("testFunction.myfunc#7b40f56c086de5aa91dc467456329ed2");
261261
assertThat(record.getStatus()).isEqualTo(DataRecord.Status.INPROGRESS);
262262
assertThat(record.getResponseData()).isEqualTo("Response");
263263
assertThat(status).isEqualTo(0);
@@ -272,15 +272,15 @@ public void getRecord_cacheEnabledNotExpired_shouldReturnRecordFromCache() throw
272272

273273
Instant now = Instant.now();
274274
DataRecord dr = new DataRecord(
275-
"testFunction.myfunc#47261bd5b456f400f8d191cfb3a7482f",
275+
"testFunction.myfunc#7b40f56c086de5aa91dc467456329ed2",
276276
DataRecord.Status.COMPLETED,
277277
now.plus(3600, ChronoUnit.SECONDS).getEpochSecond(),
278278
"result of the function",
279279
null);
280-
cache.put("testFunction.myfunc#47261bd5b456f400f8d191cfb3a7482f", dr);
280+
cache.put("testFunction.myfunc#7b40f56c086de5aa91dc467456329ed2", dr);
281281

282282
DataRecord record = persistenceStore.getRecord(JsonConfig.get().getObjectMapper().valueToTree(event), now);
283-
assertThat(record.getIdempotencyKey()).isEqualTo("testFunction.myfunc#47261bd5b456f400f8d191cfb3a7482f");
283+
assertThat(record.getIdempotencyKey()).isEqualTo("testFunction.myfunc#7b40f56c086de5aa91dc467456329ed2");
284284
assertThat(record.getStatus()).isEqualTo(DataRecord.Status.COMPLETED);
285285
assertThat(record.getResponseData()).isEqualTo("result of the function");
286286
assertThat(status).isEqualTo(-1); // getRecord must not be called (retrieve from cache)
@@ -295,15 +295,15 @@ public void getRecord_cacheEnabledExpired_shouldReturnRecordFromPersistence() th
295295

296296
Instant now = Instant.now();
297297
DataRecord dr = new DataRecord(
298-
"testFunction.myfunc#47261bd5b456f400f8d191cfb3a7482f",
298+
"testFunction.myfunc#7b40f56c086de5aa91dc467456329ed2",
299299
DataRecord.Status.COMPLETED,
300300
now.minus(3, ChronoUnit.SECONDS).getEpochSecond(),
301301
"result of the function",
302302
null);
303-
cache.put("testFunction.myfunc#47261bd5b456f400f8d191cfb3a7482f", dr);
303+
cache.put("testFunction.myfunc#7b40f56c086de5aa91dc467456329ed2", dr);
304304

305305
DataRecord record = persistenceStore.getRecord(JsonConfig.get().getObjectMapper().valueToTree(event), now);
306-
assertThat(record.getIdempotencyKey()).isEqualTo("testFunction.myfunc#47261bd5b456f400f8d191cfb3a7482f");
306+
assertThat(record.getIdempotencyKey()).isEqualTo("testFunction.myfunc#7b40f56c086de5aa91dc467456329ed2");
307307
assertThat(record.getStatus()).isEqualTo(DataRecord.Status.INPROGRESS);
308308
assertThat(record.getResponseData()).isEqualTo("Response");
309309
assertThat(status).isEqualTo(0);
@@ -347,8 +347,8 @@ public void deleteRecord_cacheEnabled_shouldDeleteRecordFromCache() {
347347
persistenceStore.configure(IdempotencyConfig.builder()
348348
.withUseLocalCache(true).build(), null, cache);
349349

350-
cache.put("testFunction#47261bd5b456f400f8d191cfb3a7482f",
351-
new DataRecord("testFunction#47261bd5b456f400f8d191cfb3a7482f", DataRecord.Status.COMPLETED, 123, null, null));
350+
cache.put("testFunction#7b40f56c086de5aa91dc467456329ed2",
351+
new DataRecord("testFunction#7b40f56c086de5aa91dc467456329ed2", DataRecord.Status.COMPLETED, 123, null, null));
352352
persistenceStore.deleteRecord(JsonConfig.get().getObjectMapper().valueToTree(event), new ArithmeticException());
353353
assertThat(status).isEqualTo(3);
354354
assertThat(cache).isEmpty();

0 commit comments

Comments
 (0)