A Flexible Heuristic Closed-Loop Algorithm for QoS Assurance in 5G End-to-End Network Slices