Yes, everything works from my client machine. curl etc. from command prompt. Thats how I figured out, something in my code thats not working properly. But it was hard to debug, as it didn't throw any exception.
Well, I was able to fix the issue. I think it was some kind of version conflict with Spring IO, ES, and Java 1.8. I still don't know the reason btw. I started with a "clean slate" for ES 2.3.3 (instead of porting my old code that was perfectly running ES 1.7) and one by one added the necessary entries in pom.xml.
Current working configuration is Spring IO 4.2.6. RELEASE with Java 1.8 and ES 2.3.3
Now I am able to use the same aforementioned code and inject data in ES.
thank you very much for your support in resolving the issue.