A Durham company made a decision to stay local for a nearly 900-job expansion, after considering but ultimately rejecting Massachusetts.