gateway: always select a new gateway when threshold != 0