public function orphaned($master, array $processIds)
    {
        $time = Chronos::now()->getTimestamp();

        $shouldRemove = array_diff($this->connection()->hkeys(
            $key = "{$master}:orphans"
        ), $processIds);

        if (! empty($shouldRemove)) {
            $this->connection()->hdel($key, ...$shouldRemove);
        }

        $this->connection()->pipeline(function ($pipe) use ($key, $time, $processIds) {
            foreach ($processIds as $processId) {
                $pipe->hsetnx($key, $processId, $time);
            }
        });
    }
public function orphaned($master, array $processIds)
    {
        $time = Chronos::now()->getTimestamp();

        $shouldRemove = array_diff($this->connection()->hkeys(
            $key = "{$master}:orphans"
        ), $processIds);

        if (! empty($shouldRemove)) {
            $this->connection()->hdel($key, ...$shouldRemove);
        }

        $this->connection()->pipeline(function ($pipe) use ($key, $time, $processIds) {
            foreach ($processIds as $processId) {
                $pipe->hsetnx($key, $processId, $time);
            }
        });
    }
public function orphaned ( $ master , array $ processIds ) { $ time = Chronos :: now ( ) -> getTimestamp ( ) ; $ shouldRemove = array_diff ( $ this -> connection ( ) -> hkeys ( $ key = "{$master}:orphans" ) , $ processIds ) ; if ( ! empty ( $ shouldRemove ) ) { $ this -> connection ( ) -> hdel ( $ key , ... $ shouldRemove ) ; } $ this -> connection ( ) -> pipeline ( function ( $ pipe ) use ( $ key , $ time , $ processIds ) { foreach ( $ processIds as $ processId ) { $ pipe -> hsetnx ( $ key , $ processId , $ time ) ; } } ) ; }
Record the given process IDs as orphaned.

@param  string  $master
@param  array  $processIds
@return void
Record the given process IDs as orphaned .