Skip to content

read error on connection #33

@rkang30

Description

@rkang30

Hi,

I get error "read error on connection" when I emit data. The connection seems to be ok though. When I create an emitter object, I get a connected object (please see below)

$redis = new \Redis();
$redis->connect($_SERVER['SERVER_ADDR'], '8090');
$emitter = new \SocketIO\Emitter($redis);
dd($emitter);

Emitter {#514 ▼
+"redis": Redis {#519 ▼
isConnected: true
host: "172.16.6.66"
port: 8090
auth: null
dbNum: 0
timeout: 0.0
persistentId: null
options: {▼
READ_TIMEOUT: 0.0
SERIALIZER: NONE
PREFIX: null
SCAN: NORETRY
}
}
+"key": "socket.io#emitter"
+"_rooms": []
+"_flags": []
}

However, whenever I try to emit data, I get errors.

$emitter->broadcast->emit('event', array('name' => 'foo'));

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions