summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEvgeny Zinoviev <me@ch1p.io>2021-03-11 01:37:53 +0300
committerEvgeny Zinoviev <me@ch1p.io>2021-03-11 01:37:53 +0300
commitdc2fff8a678df1dbbd2a87d6e7fefa9bb036347c (patch)
tree47a8e6fd53186bf99d10357521435597e1787ac3
parent517160645d75e5e7c94a99087630b9c3fc0c3823 (diff)
update readme
-rw-r--r--README.md8
1 files changed, 4 insertions, 4 deletions
diff --git a/README.md b/README.md
index 7f2379e..fd01fd1 100644
--- a/README.md
+++ b/README.md
@@ -11,14 +11,14 @@ composer require ch1p/jobd-client
## Usage
-The API is compact and simple, just read the code of `Client.php`.
+The API is compact and simple, just read `WorkerClient.php` and `MasterClient.php`.
Here's a small example.
```php
try {
- $jobd = new jobd\Client(jobd\Client::MASTER_PORT, '127.0.0.1');
-} catch (Exception $e) {
+ $jobd = new jobd\MasterClient();
+} catch (jobd\Exception $e) {
die("Failed to connect.\n");
}
@@ -28,7 +28,7 @@ try {
// get status from master
$status = $jobd->status()->getData();
-} catch (Exception $e) {
+} catch (jobd\Exception $e) {
die('jobd error: '.$e->getMessage()."\n");
}