Fix some monkey-patches to make them compatible with ZODB5
See also https://github.com/zopefoundation/ZEO/pull/63 and nexedi/erp5!1095 No error in testCMFActivity and testConflictResolution. For the only error in testInvalidationBug, see comment. But this commit is not enough for ZODB5. The only known issue so far is the use of newer pickle protocol, which breaks export of ZODB data and requires non-trivial changes in our XMLExportImport/ppml code. So for the moment, many failures in testBusinessTempate.