The United States and India signed a major military communications agreement Thursday during a visit by Secretary of State Mike Pompeo and Defense Secretary Jim Mattis to New Delhi, highlighting the growing partnership between the two nations as they seek to manage a rising China.

The agreement, which had been under discussion for more than a decade, will allow India to receive military-grade communications equipment from the United States and permit the exchange of real-time encrypted information on platforms used by theIndian and U.S. armed forces.

Pompeo and Mattis were in India for their first joint meeting with their Indian counterparts, a conclave aimed at showcasing areas of agreement between the world’s two largest democracies – while downplaying areas of tension.

The relationship between the United States and India has entered “a new era,” Pompeo said, adding that Thursday’s meeting was “symbolic of our increasingly close partnership.”

At a grand strategic level, both the United States and India are eager to develop closer ties. Each views the other as a useful partner in checking China’s ambitions in Asia and as an ally in counterterrorism efforts. Sales of U.S. military equipment to India have increased considerably over the past decade, and the United States is now India’s second-largest arms supplier.

The Communications Compatibility and Security Agreement, signed Thursday by Mattis and his Indian counterpart, is a type of foundational accord that the United States uses as a framework for military cooperation with other countries. (Washington has such agreements with fewer than 30 nations, Reuters news agency reported.)

India had hesitated to conclude the agreement partly out of worries about the United States getting access to Indian military communications.

“If the Indian establishment is willing to move forward with politically tricky but operationally meaningful agreements, I take that as a good sign,” said Joshua White, who served as a senior adviser on South Asian affairs at the National Security Council under the Obama administration.

Indeed, India’s defense minister, Nirmala Sitharaman, sounded ebullient about the prospects for further collaboration. Defense cooperation “has emerged as the most significant dimension of our strategic partnership and a key driver of our overall bilateral relationship,” she said Thursday. The momentum in that arena has “imbued a tremendous positive energy” to U.S.-India relations, she said.

But in realms apart from defense, the relationship has progressed more haltingly. India is one of many targets in President Trump’s crusade to reduce the U.S. trade deficit, and the two countries have imposed tit-for-tat tariffs. The Trump administration is pushing India to increase its imports of U.S. goods and to drastically reduce its purchases of Iranian oil or face sanctions.

Thursday’s meeting was supposed to be held in Washington but was postponed twice by the Trump administration. Pompeo struck a conciliatory tone about the areas of friction between the two countries in remarks to reporters after a half day of meetings in New Delhi.

Many countries, including India, “are in a place where it takes them a little bit of time to unwind” oil imports from Iran, he said. “We’ll work with them, I’m sure, to find an outcome that makes sense.” The Trump administration has withdrawn from a 2015 nuclear agreement with Iran and is reimposing nuclear-related sanctions that were lifted as part of the deal.

Pompeo also said the United States would work with India on another area of concern – India’s upcoming purchase of a Russian missile and air-defense system known as the S-400. The purchase will violate sanctions instituted by Congress on arms purchases from Russia, but lawmakers have allowed the possibility of a presidential waiver.

Pompeo said no decision has been made on whether to grant India a waiver. But “we do understand the history of India’s relationship with Russia,” he said. “Our effort here is not to penalize great strategic partners like India.”

Pompeo’s visit to India came a day after he visited Pakistan, where he pressed the country’s army and its newly elected prime minister to make concrete progress in confronting Afghan Taliban fighters inside Pakistan. The Trump administration recently suspended $300 million in aid to Pakistan over its failures in the fight against such militants – a tough approach welcomed by India.

Pompeo and Mattis also met with Indian Prime Minister Narendra Modi on Thursday afternoon. India has invited Trump to attend its annual Republic Day celebration in January, featuring a grand military parade, but it is unclear whether Trump will attend.