Foren

FacesContext.getCurrentInstance() returning null

Anandababu Bolisetti, geändert vor 9 Jahren.

FacesContext.getCurrentInstance() returning null

New Member Beiträge: 18 Beitrittsdatum: 21.01.14 Neueste Beiträge
Hi All,

We are facing strange issue with our JSF portlets (running on primefaces) where the FacesContext.getCurrentInstace() method returns null in almost all liferay internal classes. This issue is observed while we are running performance test scripts for multiple users logging in at same time and performing operations on a same portlet.

I have attached the server log for reference.

As far as we see, the only change we see is that some of the managed beans are changed from view scope to application scope.

We are stuck up with this issue from last 2 days. Please help resolve this.

Thanks in advance.
thumbnail
Neil Griffin, geändert vor 9 Jahren.

RE: FacesContext.getCurrentInstance() returning null

Liferay Legend Beiträge: 2655 Beitrittsdatum: 27.07.05 Neueste Beiträge
Hi Anandababu,

I would recommend that you put breakpoints in FacesContext.setCurrentInstance(FacesContext) and FacesContext.release() and see when and why they are being called.

Kind Regards,

Neil
Anandababu Bolisetti, geändert vor 9 Jahren.

RE: FacesContext.getCurrentInstance() returning null

New Member Beiträge: 18 Beitrittsdatum: 21.01.14 Neueste Beiträge
Hi Neil,

The error is not happening with our custom portlet classes. Also it is not happening when we are doing a manual test with single user, but it is happening while running the automated script to use multiple users.
thumbnail
Neil Griffin, geändert vor 9 Jahren.

RE: FacesContext.getCurrentInstance() returning null

Liferay Legend Beiträge: 2655 Beitrittsdatum: 27.07.05 Neueste Beiträge
Hi Anandababu,

Assuming you are using Liferay Portal 6.2, please try adding this to your portal-ext.properties file, restart your server, and let us know if you still see the problem:

layout.parallel.render.enable=false


Kind Regards,

Neil