Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Documentation Typos #2

Merged
merged 1 commit into from
Sep 17, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ as argument. Here's an example:
use Junges\Kafka\Facades\Kafka;

Kafka::publishOn('broker', 'topic')
->withCOnfigOption('property-name', 'property-value')
->withConfigOption('property-name', 'property-value')
->withConfigOptions([
'property-name' => 'property-value'
]);
Expand All @@ -63,7 +63,7 @@ To disable debug mode, you can use `->withDebugEnabled(false)`, or `withDebugDis
use Junges\Kafka\Facades\Kafka;

Kafka::publishOn('broker', 'topic')
->withCOnfigOption('property-name', 'property-value')
->withConfigOption('property-name', 'property-value')
->withConfigOptions([
'property-name' => 'property-value'
])
Expand Down Expand Up @@ -104,15 +104,15 @@ $message = new Message(
key: 'kafka key here'
)

Kafka::publisOn('broker', 'topic')->withMessage($message);
Kafka::publishOn('broker', 'topic')->withMessage($message);
```

The `withMessageKey` method sets only a key in your message.

```php
use Junges\Kafka\Facades\Kafka;

Kafka::publisOn('broker', 'topic')->withMessageKey('key', 'value');
Kafka::publishOn('broker', 'topic')->withMessageKey('key', 'value');
```

### Using Kafka Keys
Expand All @@ -122,7 +122,7 @@ If you want to use a key in your message, you should use the `withKafkaKey` meth
```php
use Junges\Kafka\Facades\Kafka;

Kafka::publisOn('broker', 'topic')->withKafkaKey('your-kafka-key');
Kafka::publishOn('broker', 'topic')->withKafkaKey('your-kafka-key');
```

## Sending the message to Kafka
Expand All @@ -132,7 +132,7 @@ After configuring all your message options, you must use the `send` method, to s
use Junges\Kafka\Facades\Kafka;

/** @var \Junges\Kafka\Producers\ProducerBuilder $producer */
$producer = Kafka::publisOn('broker', 'topic')
$producer = Kafka::publishOn('broker', 'topic')
->withConfigOptions(['key' => 'value'])
->withKafkaKey('your-kafka-key')
->withKafkaKey('kafka-key')
Expand Down