Japan’s currency headache comes at a critical juncture. The country’s large boost in military spending was intended to fortify defenses as Tokyo confronts mounting missile threats from North Korea and other challenges posed by China, including fears of a potential China-Taiwan conflict.