Skip to content

Instantly share code, notes, and snippets.

View hunken's full-sized avatar
🏠
Working from home

hunken.dev hunken

🏠
Working from home
View GitHub Profile

Kafka 0.11.0.0 (Confluent 3.3.0) added support to manipulate offsets for a consumer group via cli kafka-consumer-groups command.

  1. List the topics to which the group is subscribed
kafka-consumer-groups --bootstrap-server <kafkahost:port> --group <group_id> --describe

Note the values under "CURRENT-OFFSET" and "LOG-END-OFFSET". "CURRENT-OFFSET" is the offset where this consumer group is currently at in each of the partitions.

  1. Reset the consumer offset for a topic (preview)
@hunken
hunken / PHPExcel_Basics.md
Created April 13, 2018 04:11 — forked from yajra/PHPExcel_Basics.md
PHPExcel Notes and code snippets

Basics

Creating a new PHPExcel Object.

    $this->PHPExcel = new PHPExcel();

Working with sheets

Creating a new sheet:

@hunken
hunken / demo.module
Created January 11, 2016 09:10 — forked from pascalduez/demo.module
Drupal 7 — Basic Ajax form submit (Ajax framework)
<?php
/**
* @file
* Demo module, Basic Ajax form submit (Ajax framework).
*/
/**
* Implements hook_menu().
*/