We consider several versions of the job assignment problem for an M/M/m queue with servers of different speeds. When there are two classes of customers, primary and secondary, the number of secondary customers is infinite, and idling is not permitted, we develop an intuitive proof that the optimal policy that minimizes the mean waiting time has a threshold structure. That is, for each server, there is a server-dependent threshold such that a primary customer will be assigned to that server if and only if the queue length of primary customers meets or exceeds the threshold. Our key argument can be generalized to extend the structural result to models with impatient customers, discounted waiting time, batch arrivals and services, geometrically distributed service times, and a random environment. We show how to compute the optimal thresholds, and study the impact of heterogeneity in server speeds on mean waiting times. We also apply the same machinery to the classical slow-server problem without secondary customers, and obtain more general results for the two-server case and strengthen existing results for more than two servers.