A Framework for Updating Functionalities Based on the MAPE Loop Mechanism