Unfortunately, Japan is highly racist in their sponsorship of immigrants. They will take white people over other races every time. I'm not happy to recall the treatment I saw Indian tourists receive during my time in Shinjuku.
I lived in Japan for several years and found most people there to be open and friendly to other races. I had friends from India, Nigeria, China, Korea, Vietnam, Philippines, Brazil, US and Europe. I don't know that any of them felt particularly discriminated against because of their race. I certainly didn't, except perhaps once when a really old guy tried to hit me with his cane. But that's not to say that it doesn't exist. I just don't think it's rampant everywhere in Japan.
I'm not saying that it exhibits heavily in everyday interactions. I saw discrimination primarily when it came to club admittance and service at bars. But the most easily seen discrimination is definitely in hiring practices and "do I want this person in my country". There's a looooot of HR training and protections that need to exist in Japanese companies and simply don't.
I don't know if this is done in good faith, but perhaps more as a "screw you" to China. India and China don't have the best relations, nor does Japan wish to see that change in the future.