Bank of Japan Gov. Haruhiko Kuroda changed the course of global markets when he unleashed a $3.4 trillion firehose of Japanese cash on the investment world. Now Kazuo Ueda is likely to dismantle his legacy, setting the stage for a flow reversal that risks sending shockwaves through the global economy.

Just over a week before a momentous leadership change at the BOJ, investors are gearing up for the seemingly inevitable end to a decade of ultralow interest rates that punished domestic savers and sent a wall of money overseas. The exodus accelerated after Kuroda moved to suppress bond yields in 2016, culminating in a mountain of offshore investments worth more than two-thirds of Japan’s economy.

All this risks unraveling under the new governor Ueda, who may have little choice but to end the world’s boldest easy-money experiment just as rising interest rates elsewhere are already jolting the international banking sector and threatening financial stability. The stakes are enormous: Japanese investors are the biggest foreign holders of U.S. government bonds and own everything from Brazilian debt to European power stations to bundles of risky loans stateside.