Efficient optimization techniques for traffic engineering