Important Notice - Forums is archived
To simplify things and help our users to be more productive, we have archived the current forum and focus our efforts on helping developers on Stack Overflow. You can post new questions on Stack Overflow or join our Discord channel.

Vaadin lets you build secure, UX-first PWAs entirely in Java.
Free ebook & tutorial.
Liferay ServiceContext in Vaadin Portlet
Hi guys,
I developed a vaadin portlet and i deployed to liferay.
In this portlet I have to create liferay user and i used :
User operatore = UserLocalServiceUtil.addUser(all parameters......,serviceContext);
How get ServiceContext from liferay into Vaadin Portlet ?
I tried with :
PortletRequest portleRequest = ((VaadinPortletRequest)vaadinrequest).getPortletRequest();
ServiceContext serviceContext = ServiceContextFactory.getInstance(portleRequest);
but i have Nullpointer exception on this row "ServiceContext serviceContext = ServiceContextFactory.getInstance(portleRequest);"
portleRequest is not null
Can you help me ??
Thank you.