A Chinese saying sums up the government's efforts to immunize itself from global price shocks: a half-closed door will not shut out everything.
Worried that a surge in international energy and agricultural prices could stoke inflation, which is already at 11-year highs, China has stiffened its broad self-sufficiency in food by deterring agricultural exports, including those of rice, wheat, flour and fertilizer, through export quotas and taxes.
Yet though China is a net exporter of farm produce, inflation is still sneaking in through the agricultural commodities that China does import, as well as through a soaring bill for crude oil and metals to feed its ravenous industries.
Even for those things it does not buy, inflationary expectations are driving up prices, economists say.
"The Chinese market is linked to the global market by thousands of threads," says Qi Jingmei, a senior economist at the State Information Centre. "You can't cut them off completely."
Qi's think tank reports to the State Council, China's cabinet.
A spike in pork and other fresh food prices pushed up China's inflation to a 12-year peak of 8.7 percent in February. It ebbed a little to 8.3 percent in March.
As well as limiting exports, the central government has tried to keep a lid on prices by releasing supplies from the state's reserves of wheat, rice and pork. It has also increased subsidies to spur farmers to raise more hogs and grow more grain.
However, some economists say such measures will have only a fleeting impact and could eventually distort market-based pricing, thus discouraging farmers from planting more.
"The potential for prices to go up may well rise in future, because you can't always tap the grain reserves," says Huang Jikun at the Center for Chinese Agricultural Policy at the Chinese Academy of Sciences.
Huang says international agricultural inflation accounted for about 40 percent of the recent spike in consumer prices.
Jun Ma, Deutsche Bank's chief China economist, agrees that surging overseas grain prices as well as rising fertilizer costs were helping to push up domestic grain prices, even though the only grain China imports is soybean.
"The surge in rice prices in Asia following many Asian countries' restrictions on rice exports may have a psychological impact on Chinese grain," he says in a recent note to clients.
Some Asian rice prices have almost trebled this year. Rising global prices have sparked protests from Haiti to Cameroon.
"The government and investors should be alert to the possibility - although still remote for the moment - of hoarding and even panic buying of grain (typically on speculation of potential price increases) in China," Ma says.
However, some other economists are much more relaxed.
"The potential inflationary impact of rapidly rising international grain prices on China will be insignificant," says Qing Wang, a senior economist at Morgan Stanley.
He says in a recent note that China was able to maintain self-sufficiency in major grains and had limited exposure to the vagaries of international markets, especially in the short term.
Jonathan Anderson at UBS also says there was little correlation between Chinese and global trends.
For worriers like Huang, the question is how long China's State grain reserves can last. Premier Wen Jiabao disclosed in March that the reserves were 150-200 million tons - much more than the market had guessed.
Although China had enough stocks for the next few months, it might not be enough in the longer term as farmers diversify from grains due to low domestic prices, Huang says.
"China should let grain prices rise now so farmers have a greater incentive to plant more and earn more as well," he says.
Global food insecurity would make buying from abroad difficult for China, Huang adds. Any sign of purchases from China would send global grain prices through the roof.
Qi at the State Information Centre has a different concern - that export quotas and taxes, though working now to hold prices in check, would gradually lose their effectiveness in the face of market forces.
The Ministry of Commerce has already warned domestic exporters against shipping grains and flour abroad via Hong Kong and Macau, she notes.
"However, if global prices rise to a level where exports become much more profitable despite the high taxes, then they will do so," Qi says.