sidorares/node-mysql2 — pull request #83 by sidorares (2014-02-23 08:25:27+00:00)
Title: binlog protocol

see #78

Currently only implemented RotateEvent, FormatDescriptionEvent and QueryEvent.

output of `examples/binlog-watcher.js` example while `create database testtest1` and `drop database testtest1` executed on server:

```
{
slaveProxyId: 3,
executionTime: 0,
errorCode: 0,
schema: 'testtest1',
statusVars:
[ [ 0, 0 ],
[ 1, 1075838976 ],
[ 6, 'std' ],
[ 4, [Object] ],
[ 12, [Object] ] ],
query: 'create database testtest1',
name: 'QueryEvent',
header:
{ timestamp: 1393140952,
eventType: 2,
serverId: 1,
eventSize: 105,
logPos: 647,
flags: 8 } }
{ slaveProxyId: 3,
executionTime: 0,
errorCode: 0,
schema: 'testtest1',
statusVars: [ [ 0, 0 ], [ 1, 1075838976 ], [ 6, 'std' ], [ 4, [Object] ] ],
query: 'drop database testtest1',
name: 'QueryEvent',
header:
{ timestamp: 1393140966,
eventType: 2,
serverId: 1,
eventSize: 91,
logPos: 738,
flags: 8 } }
```