- if (commitsEnabled)
- {
- log.info("{} - Commiting offsets for all previously assigned partitions", id);
- try
- {
- consumer.commitSync();
- }
- catch (Exception e)
- {
- log.warn("{} - Could not commit offsets in onPartitionsRevoked():", id, e);
- }
- }
-