public function update(MasterSupervisor $master)
    {
        $supervisors = $master->supervisors->map->name->all();

        $this->connection()->pipeline(function ($pipe) use ($master, $supervisors) {
            $pipe->hmset(
                'master:'.$master->name, [
                    'name' => $master->name,
                    'pid' => $master->pid(),
                    'status' => $master->working ? 'running' : 'paused',
                    'supervisors' => json_encode($supervisors),
                ]
            );

            $pipe->zadd('masters',
                Chronos::now()->getTimestamp(), $master->name
            );

            $pipe->expire('master:'.$master->name, 15);
        });
    }
public function update(MasterSupervisor $master)
    {
        $supervisors = $master->supervisors->map->name->all();

        $this->connection()->pipeline(function ($pipe) use ($master, $supervisors) {
            $pipe->hmset(
                'master:'.$master->name, [
                    'name' => $master->name,
                    'pid' => $master->pid(),
                    'status' => $master->working ? 'running' : 'paused',
                    'supervisors' => json_encode($supervisors),
                ]
            );

            $pipe->zadd('masters',
                Chronos::now()->getTimestamp(), $master->name
            );

            $pipe->expire('master:'.$master->name, 15);
        });
    }
public function update ( MasterSupervisor $ master ) { $ supervisors = $ master -> supervisors -> map -> name -> all ( ) ; $ this -> connection ( ) -> pipeline ( function ( $ pipe ) use ( $ master , $ supervisors ) { $ pipe -> hmset ( 'master:' . $ master -> name , [ 'name' => $ master -> name , 'pid' => $ master -> pid ( ) , 'status' => $ master -> working ? 'running' : 'paused' , 'supervisors' => json_encode ( $ supervisors ) , ] ) ; $ pipe -> zadd ( 'masters' , Chronos :: now ( ) -> getTimestamp ( ) , $ master -> name ) ; $ pipe -> expire ( 'master:' . $ master -> name , 15 ) ; } ) ; }
Update the information about the given master supervisor.

@param  \Laravel\Horizon\MasterSupervisor  $master
@return void
Update the information about the given master supervisor .