In China, the Sui dynasty was replaced by the Tang dynasty, which set up its military bases from Korea to Central Asia, and was next to the Umayyads' later. China began to reach its height. Silla allied itself with the Tang dynasty, subjugating Baekje and defeating Goguryeo to unite the Korean Peninsula under one ruler.