Given the amount of money Japan would have spent on losing, its quite likely that there would have been severe political upheaval within Japan, which could have gone either way, left or right, but would have weakened Japan in the short-term. However, when you see how far they had come by 1904, it seems unlikely that it would have destabiilised them in the long-term. A note though, would be that Korean independence would have been more secure, though this would depend longer term on whether Russia tried to make a protectorate out of them.
Best Regards
Grey Wolf