CLAM: Managing Cross-layer Adaptation in Service-Based Systems