Discussion posts and replies are publicly visible
YOu can try sending parameters in the url when using web component.
For example
Another option would be to create your own plugin in java as you said before.
thats exactly what I though about to at least initially test it. It didnt work.
IN that case,.... the option is the second one.. implement your own plugin