Skip to content

Commit

Permalink
Adding some logging
Browse files Browse the repository at this point in the history
  • Loading branch information
jessecollier committed Apr 13, 2017
1 parent c41173f commit e790aa8
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/main/java/dbtucker/connect/kinesis/KinesisSinkTask.java
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,12 @@ public void put(Collection<SinkRecord> collection) {
final PutRecordsRequestEntry put = new PutRecordsRequestEntry();
put.setData(ByteBuffer.wrap(record.value().toString().getBytes()));
if (record.key() != null) {
log.warn("I have a non-null record.key()=>'" + record.key() + "' record.value()=>'" + record.value()
+ "' record.topic()=>'" + record.topic() + "' toSring()=>'" + record.key().toString() + "'"
);
if (record.keySchema() != null) {
// TODO: correctly parse schema'ed key

put.setPartitionKey(record.key().toString()); // assume toString handles real Strings correctly
} else {
put.setPartitionKey(record.key().toString()); // assume toString handles real Strings correctly
Expand Down

0 comments on commit e790aa8

Please sign in to comment.