Refactor rsync

Update rsync to working code
Add methods to use web sockets to communicate with client to perform a sync
I think you probably want to rename `setCallback` to `findCallback` or `maybeCallback` and do what I showed above.