DUE TO SPAM, SIGN-UP IS DISABLED. Goto Selfserve wiki signup and request an account.
...
- Adding the public ProducerRecord<byte[], byte[]> deadLetterQueueRecord; attribute in the ProductionExceptionHandlerResponse ProcessingHandlerResponse
| Code Block | ||
|---|---|---|
| ||
public interface DeserializationExceptionHandler extends Configurable {
...
/**
* Enumeration that describes the response from the exception handler.
*/
enum DeserializationHandlerResponse {
. . .
public DeserializationHandlerResponse withDeadLetterQueueRecords(Iterable<org.apache.kafka.clients.producer.ProducerRecord<byte[], byte[]>> deadLetterQueueRecords) {
this.deadLetterQueueRecord = deadLetterQueueRecord;
return this;
}
}
}
|
ProcessingExceptionHandler
...
.java
Changes:
- Adding the public ProducerRecord<byte[], byte[]> deadLetterQueueRecord; attribute in
...
- the ProductionExceptionHandlerResponse
| Code Block | ||
|---|---|---|
| ||
public interface DeserializationExceptionHandler extends Configurable {
...
/**
* Enumeration that describes the response from the exception handler.
*/
enum DeserializationHandlerResponse {
. . .
public DeserializationHandlerResponse withDeadLetterQueueRecords(Iterable<org.apache.kafka.clients.producer.ProducerRecord<byte[], byte[]>> deadLetterQueueRecords) {
this.deadLetterQueueRecord = deadLetterQueueRecord;
return this;
}
}
}
|
ErrorHandlerContext.java
Changes:
- Adding the public byte[] sourceRawKey and byte[] sourceRawValue in the ErrorHandlerContext pointing to the source record data
| Code Block | ||||
|---|---|---|---|---|
| ||||
/**
* ErrorHandlerContext interface
*/
public interface ErrorHandlerContext {
. . .
/**
* Return the non-deserialized byte[] of the input message key if the context has been triggered by a message.
*
* <p> If this method is invoked within a {@link Punctuator#punctuate(long)
* punctuation callback}, or while processing a record that was forwarded by a punctuation
* callback, it will return null.
*
* <p> If this method is invoked in a sub-topology due to a repartition, the returned key would be one sent
* to the repartition topic.
*
* <p> Always returns null if this method is invoked within a
* {@link ProductionExceptionHandler.handle(ErrorHandlerContext, ProducerRecord, Exception)}
*
* @return the raw byte of the key of the source message
*/
byte[] sourceRawKey();
/**
* Return the non-deserialized byte[] of the input message value if the context has been triggered by a message.
*
* <p> If this method is invoked within a {@link Punctuator#punctuate(long)
* punctuation callback}, or while processing a record that was forwarded by a punctuation
* callback, it will return null.
*
* <p> If this method is invoked in a sub-topology due to a repartition, the returned value would be one sent
* to the repartition topic.
*
* <p> Always returns null if this method is invoked within a
* {@link ProductionExceptionHandler.handle(ErrorHandlerContext, ProducerRecord, Exception)}
*
* @return the raw byte of the value of the source message
*/
byte[] sourceRawValue();
. . .
} |
Compatibility, Deprecation, and Migration Plan
...