Skip to content

Commit 6fa478e

Browse files
authored
Update MSKFirehoseResponse.java
Expanded the Lombok import, updated java doc for the class and removed the record constructor.
1 parent feec28f commit 6fa478e

File tree

1 file changed

+12
-10
lines changed

1 file changed

+12
-10
lines changed

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

+12-10
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,17 @@
33
import java.nio.ByteBuffer;
44
import java.util.List;
55

6-
import lombok.*;
6+
import lombok.AllArgsConstructor;
7+
import lombok.Builder;
8+
import lombok.Data;
9+
import lombok.NoArgsConstructor;
710

811
/**
912
* Response model for Amazon Data Firehose Lambda transformation with MSK as a source.
13+
* [+] Amazon Data Firehose Data Transformation - Data Transformation and Status Model - <a href="https://docs.aws.amazon.com/firehose/latest/dev/data-transformation.html#data-transformation-status-model">...</a>
14+
* OK : Indicates that processing of this item succeeded.
15+
* ProcessingFailed : Indicate that the processing of this item failed.
16+
* Dropped : Indicates that this item should be silently dropped
1017
*/
1118

1219
@Data
@@ -17,12 +24,12 @@
1724
public class MSKFirehoseResponse {
1825

1926
public enum Result {
20-
27+
2128
/**
2229
* Indicates that processing of this item succeeded.
2330
*/
2431
Ok,
25-
32+
2633
/**
2734
* Indicate that the processing of this item failed
2835
*/
@@ -36,19 +43,14 @@ public enum Result {
3643
public List<Record> records;
3744

3845
@Data
39-
@Builder(setterPrefix = "with")
4046
@NoArgsConstructor
47+
@Builder(setterPrefix = "with")
48+
@AllArgsConstructor
4149

4250
public static class Record {
4351
public String recordId;
4452
public Result result;
4553
public ByteBuffer kafkaRecordValue;
4654

47-
public Record(String recordId, Result result, ByteBuffer kafkaRecordValue) {
48-
super();
49-
this.recordId = recordId;
50-
this.result = result;
51-
this.kafkaRecordValue = kafkaRecordValue;
52-
}
5355
}
5456
}

0 commit comments

Comments
 (0)