Skip to content

Commit 6146a38

Browse files
committed
Added auth info to README
1 parent a170699 commit 6146a38

File tree

1 file changed

+30
-1
lines changed

1 file changed

+30
-1
lines changed

README.md

Lines changed: 30 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ $videoQueue->add(Queue::DEFAULT_JOB_NAME, [
3434
]);
3535
```
3636

37-
If you want to use `predis` as Redis client:
37+
If you want to use `predis` as Redis client (example configuration):
3838

3939
```php
4040
<?php
@@ -48,6 +48,9 @@ $videoQueue = new Queue(
4848
new QueueOpts([
4949
'redis' => new RedisConfig([
5050
'driver' => 'predis',
51+
'host' => '127.0.0.1',
52+
'port' => 6379,
53+
'password' => '',
5154
]),
5255
])
5356
);
@@ -58,6 +61,32 @@ $videoQueue->add(Queue::DEFAULT_JOB_NAME, [
5861

5962
```
6063

64+
## Configurations
65+
66+
All is configured via classes:
67+
68+
* `Ilzrv\PhpBullQueue\DTOs\RedisConfig`
69+
* `Ilzrv\PhpBullQueue\DTOs\QueueOpts`
70+
* `Ilzrv\PhpBullQueue\DTOs\JobOpts`
71+
72+
### RedisConfig
73+
* `driver` (string) Redis driver. Can be `phpredis` or `predis`. Default: `phpredis`
74+
* `host` (string) Redis host. Default: `127.0.0.1`
75+
* `port` (int) Redis port. Default: `6379`
76+
* `password` (string) Redis password. Default: `''`
77+
78+
### QueueOpts
79+
* `redis` (RedisConfig Object) Redis Configuration.
80+
* `prefix` (string) Queue prefix. Default: `bull`
81+
82+
### JobOpts
83+
* `customJobId` (string) Custom JobId. Default: `0`
84+
* `priority` (int) Job priority. Default: `0`
85+
* `lifo` (bool) Last In, First Out. Default: `false`
86+
* `attempts` (int) Job attempts. Default: `1`
87+
* `timestamp` (int) Current timestamp.
88+
* `delay` (int) Job delay. Default: `0`
89+
6190
## License
6291

6392
The MIT License (MIT). Please see [License File](LICENSE) for more information.

0 commit comments

Comments
 (0)