HANGHAI - Chinese President Xi Jinping pledged on Wednesday that China is committed to peacefully resolving disputes over territory, and warned other countries that strengthening military alliances against a third party will not benefit security.