Making binlog_player_protocol flags part of env
Adding missing parts of API.
Merge branch 'replication'