Transactional support for ad-hoc cooperations in mobile environments