Japan's stock market surged to a new record, driven by strong tech earnings and optimism over potential peace in the Middle East.