Towards Adaptive and Scalable Context-Aware Middleware