optimize mandatory plugins search