Skip to content

Commit

Permalink
Update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
mateusjunges committed Aug 2, 2024
1 parent 8986acd commit 2db480c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
6 changes: 5 additions & 1 deletion docs/advanced-usage/4-custom-committers.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,11 @@ By default, the committers provided by the `DefaultCommitterFactory` are provide
To set a custom committer on your consumer, add the committer via a factory that implements the `CommitterFactory` interface:

```php
use Junges\Kafka\Config\Config;use Junges\Kafka\Contracts\Committer;use Junges\Kafka\Contracts\CommitterFactory;use RdKafka\KafkaConsumer;use RdKafka\Message;
use Junges\Kafka\Config\Config;
use Junges\Kafka\Contracts\Committer;
use Junges\Kafka\Contracts\CommitterFactory;
use RdKafka\KafkaConsumer;
use RdKafka\Message;

class MyCommitter implements Committer
{
Expand Down
2 changes: 1 addition & 1 deletion docs/advanced-usage/5-middlewares.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ Middlewares provides a convenient way to filter and inspecting your Kafka messag

```php
$consumer = \Junges\Kafka\Facades\Kafka::consumer()
->withMiddleware(function($message, callable $next) {
->withMiddleware(function(\Junges\Kafka\Message\ConsumedMessage $message, callable $next) {
// Perform some work here
return $next($message);
});
Expand Down

0 comments on commit 2db480c

Please sign in to comment.