Skip to content

Commit 1effffd

Browse files
committed
fix readme file
1 parent 7615edf commit 1effffd

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

README.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,14 @@ With this library you will be able to introduce re-try approach in simple way:
99
1. Create configuration
1010
2. When your application start, please add next 2 rows in the begining:
1111
```php
12-
$retry = new ApacheBorys\Retry\ExceptionHandler($config);
12+
$factory = new \ApacheBorys\Retry\HandlerFactory($config);
13+
$retry = $factory->createExceptionHandler($yourContainer);
1314
$retry->initHandler();
1415
```
1516
3. Start by another process code like that:
1617
```php
17-
$worker = new ApacheBorys\Retry\MessageHandler($config);
18+
$factory = new \ApacheBorys\Retry\HandlerFactory($config);
19+
$worker = $factory->createMessageHandler($yourContainer);
1820
while (true) {
1921
$worker->processRetries();
2022
sleep(1);

0 commit comments

Comments
 (0)