Skip to content

Commit 7e88771

Browse files
authored
Fixing Queue representation in ConnectEvent.java
AWS Connect defines the Queue as an object, not a string. The object contains ARN and name (as well as address and type). I am fixing the Event model so that it correctly deserialised. For reference, I have followed the model used by the Go implementation here: https://github.com/aws/aws-lambda-go/blame/main/events/connect.go
1 parent 02d2c06 commit 7e88771

File tree

1 file changed

+10
-1
lines changed
  • aws-lambda-java-events/src/main/java/com/amazonaws/services/lambda/runtime/events

1 file changed

+10
-1
lines changed

aws-lambda-java-events/src/main/java/com/amazonaws/services/lambda/runtime/events/ConnectEvent.java

+10-1
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ public static class ContactData implements Serializable, Cloneable {
5959
private String initiationMethod;
6060
private String instanceArn;
6161
private String previousContactId;
62-
private String queue;
62+
private Queue queue;
6363
private SystemEndpoint systemEndpoint;
6464
}
6565

@@ -72,6 +72,15 @@ public static class CustomerEndpoint implements Serializable, Cloneable {
7272
private String type;
7373
}
7474

75+
@Data
76+
@Builder(setterPrefix = "with")
77+
@NoArgsConstructor
78+
@AllArgsConstructor
79+
public static class Queue implements Serializable, Cloneable {
80+
private String name;
81+
private String arn;
82+
}
83+
7584
@Data
7685
@Builder(setterPrefix = "with")
7786
@NoArgsConstructor

0 commit comments

Comments
 (0)