Refactored indices aliases api to make use of the new recently introduced generic ack mechanism

Closes #4114