Upgrade to latest Rx, and some refactoring.