Category : redis

I’ve some mistake with a job that I try to dispatch when my Redis subscribe command receive a message. I launch the Redis subscribe inside an "artisan console" command : Redis::subscribe([‘channel’], function ($message) { dipatch(new MyJob($message)) ->onQueue(‘default’) ->onConnection(‘redis’); } Job is created and I can see it on my Laravel Horizon dashboard. But it’s never ..

Read more

I created a master-slave structure with Redis, master IP 192.169.99.109, slave IP 192.168.99.108, lumen somehow I could not configure Redis … lumen database.php redis key ‘redis’ => [ ‘client’ => ‘predis’, ‘cluster’ => false, ‘options’ => [ ‘replication’ => true, ], ‘master’ => [ ‘scheme’ => ‘tcp’, ‘host’ => ‘192.168.99.109’, ‘password’ => null, ‘port’ => ..

Read more

i am using laravel 8.12 with laravel echo and redis problem : when i add chat_id to private channel name from event, socket request return 403 error however Presence channel work correctly and there is my code: controller: public function store(Request $request) { $message = Message::create([‘sender_id’ => $request->sender_id,’content’ => $request->message ,’message_type’ => ‘message’,’chat_id’ => $request->chat_id ..

Read more

I have an existing application with a ton of cache files written using the Laravel file driver. These follow a specific directory and naming structure (e.g): cache/data/ 2d/ 6e/ 2d6eece558d9143286c4a08bb5757bb2cb6e9h9kf And if it has an expiry, the first 10 chars of the file is the expiry timestamp in unix time. 1605235030a:3:{s:3:"price";s:6:"342.99"…… I want to migrate ..

Read more

Using laravel 6.8, php7.4. I’m using redis sessions, inside database.php it looks like this: ‘session’ => [ ‘host’ => env(‘REDIS_HOST’, ‘127.0.0.1’), ‘password’ => env(‘REDIS_PASSWORD’, null), ‘port’ => env(‘REDIS_PORT’, 6379), ‘database’ => env(‘REDIS_DB’, 0), ], And then in .env: REDIS_DB=0 Everything seems to be working fine with this setup, I can see session stored in redis ..

Read more

I’m getting the following error: Argument 2 passed to LaravelHorizonProvisioningPlan::__construct() must be of the type array, null given, called in /Users/camilo/Documents/development/laravel/via-express/vendor/laravel/horizon/src/ProvisioningPlan.php on line 58 I don’t know why, the horizon installation is fresh. I ran the following commands: composer require laravel/horizon php artisan vendor:publish php artisan horizon Also, can’t find anything related to this error ..

Read more

I’m a newbie in Laravel. I have a problem when I tried to built a realtime message with Laravel & ReactJS, Socket.io , Redis Errors when I start laravel-echo server file laravel-echo-server.json { "authHost": "http://localhost:8000", "authEndpoint": "/broadcasting/auth", "clients": [ { "appId": "XXXXXXXXXX", "key": "XXXXXXXXXXXXXXXXXXXXX" } ], "database": "redis", "databaseConfig": { "redis": {}, "sqlite": { "databasePath": ..

Read more

I am using Laravel 8 / homestead / Horizon / Redis / Nova Periodically, I get an error in my logs [2020-10-21 09:05:03] local.ERROR: Connection refused {"exception":"[object] (RedisException(code: 0): Connection refused at /home/julien/Code/acc/vendor/laravel/framework/src/Illuminate/Redis/Connectors/PhpRedisConnector.php:135) [stacktrace] #0 /home/julien/Code/acc/vendor/laravel/framework/src/Illuminate/Redis/Connectors/PhpRedisConnector.php(135): Redis->connect() #1 /home/julien/Code/acc/vendor/laravel/framework/src/Illuminate/Redis/Connectors/PhpRedisConnector.php(84): IlluminateRedisConnectorsPhpRedisConnector->establishConnection() #2 /home/julien/Code/acc/vendor/laravel/framework/src/Illuminate/Support/helpers.php(263): IlluminateRedisConnectorsPhpRedisConnector->IlluminateRedisConnectors{closure}() #3 /home/julien/Code/acc/vendor/laravel/framework/src/Illuminate/Redis/Connectors/PhpRedisConnector.php(105): tap() #4 /home/julien/Code/acc/vendor/laravel/framework/src/Illuminate/Redis/Connectors/PhpRedisConnector.php(28): IlluminateRedisConnectorsPhpRedisConnector->createClient() #5 /home/julien/Code/acc/vendor/laravel/framework/src/Illuminate/Redis/Connectors/PhpRedisConnector.php(32): IlluminateRedisConnectorsPhpRedisConnector->IlluminateRedisConnectors{closure}() #6 /home/julien/Code/acc/vendor/laravel/framework/src/Illuminate/Redis/RedisManager.php(110): IlluminateRedisConnectorsPhpRedisConnector->connect() ..

Read more