BRISBANE, Australia -- Eyeing Chinese aggression, President Barack Obama and the prime ministers of Japan and Australia committed Sunday to deepen their military cooperation and work together on strengthening maritime security in the Asia Pacific.

The meeting, the first since 2007 among leaders of the three allies, risked antagonizing Beijing after a week when Obama reached a surprising level of consensus with Chinese President Xi Jinping on climate change and trade, and Japan and China took steps to improve their relationship.

China has viewed Obama's efforts to deepen alliances with other countries in the region, particularly on security issues, as an attempt to counter Beijing's rise.

Get Breaking News Delivered to Your Inbox

In a joint statement following the meeting, the three leaders said they had agreed to "deepen the already strong security and defense cooperation" between their countries. They also agreed to work on boosting "maritime security capacity building" in a region rife with disputes between China and its neighbors over claims to waters and islands.

However, there were no announcements on specific military exercises or new troop deployments within the region.

White House officials insisted that the three-way talks on the sidelines of the Group of 20 economic summit were not meant to send a message to China. But in advance of Obama's meeting with Australian Prime Minister Tony Abbott and Japan's Shinzo Abe, the president pressed China to "adhere to the same rules as other nations -- whether in trade or on the seas."

"By virtue of its size and its remarkable growth, China will inevitably play a critical role in the future of this region," Obama said Saturday in a speech at the University of Queensland. "And the question is, what kind of role will it play?"

An Obama administration official said the three-way meeting had been in the works for a year. Beyond military cooperation, the leaders also discussed the U.S.-led campaign to defeat Islamic State militants in the Middle East, combat the spread of the deadly Ebola virus in West Africa, and stop Russia's destabilizing actions in Ukraine.

The conflict between Russia and Ukraine has been of particular concern in Australia, which lost 38 citizens when Moscow-backed rebels downed a commercial airliner earlier this year.

Australia was Obama's last stop on a weeklong trip that began in China and Myanmar. He arrived politically weakened at home by the Democratic Party's election defeats Nov. 4. The president has tried to show the region's leaders that he retained the ability to deliver on promises to deepen U.S. engagement in Asia and the Pacific, an effort he sees as a central part of his foreign policy.

"There are times when people have been skeptical of this rebalance, they're wondering whether America has the staying power to sustain it," Obama said. "I'm here to say that American leadership in the Asia Pacific will always be a fundamental focus of my foreign policy."

In China, he emerged with an ambitious agreement to reduce greenhouse gas emissions, as well as a deal to extend visa lengths and move forward on tariff reductions on high-tech goods.

But despite those areas of agreement, there are major sources of tension between the powers, particularly Beijing's provocative actions in territorial disputes in waters off its borders.

The conflict between China and Japan over a string of uninhabited islands in the East China Sea has been intense, with Beijing setting up an air defense zone over the area last year that was denounced by the U.S.

During a trip to Tokyo this year, Obama pledged to fulfill America's treaty obligations to defend Japan if it were to come under attack from China as part of the conflict over the islands.

In recent days, China and Japan have acted to try to ease tensions. Xi and Abe held their first-ever meeting in Beijing this past week, a discussion the Japanese leader called a "first step" toward reconciling.

Australia, the G-20 host, has played an important role in Obama's efforts to bolster the U.S. military presence in the region in order to be a counterweight to China. During a trip to Australia in 2011, Obama announced a plan to rotate 2,500 U.S. Marines through a military base in the northern city of Darwin.