U.S. Pacific Fleet commander Adm. Scott Swift said he plans to retire after being passed over for promotion to the chief of all military forces in the region in the wake of two deadly collisions involving U.S. warships.

Swift was in the running to replace Adm. Harry Harris as the head of U.S. Pacific Command (PACOM). Whoever the Pentagon chooses to replace Harris will be taking over at a time when North Korea poses a rising threat and China is flexing its military muscle.

Any replacement will have to be approved by the U.S. Senate, giving President Donald Trump limited time to find a replacement and, alternatively, the Pentagon could ask Harris to continue beyond the expected end of his three-year term in May.