(WIP) Events

Todo:
- [x] Read events from the user command response
- [x] Read events from the message stream
- [x] Make a loop to do longpolling/shortpolling
- [x] Replace std:cerr by exceptions
- [x] mutex
`GetUrl()` should always been called in the thread where `m_pJsonRpcClient` and `m_pHttpClient` are called.
The lock here is to avoid changing the msgStream url while `PullEvent` is running.

If we want to make the library completely thread-safe, more work is required, and it's not the subject of this PR.