Synthesizing self-adaptive connectors meeting functional and performance concerns