掲示板

Failed to insert facelets composites from JAR - Liferay 7 GA3

7年前 に Damien Guillermet によって更新されました。

Failed to insert facelets composites from JAR - Liferay 7 GA3

Junior Member 投稿: 44 参加年月日: 15/07/09 最新の投稿
Hello,

Firstly thank you for your work, past and present.

I'm trying to upgrade few portlets using Liferay Faces from Liferay 6.2 to Liferay 7 (GA3).
After maven dependencies upgrade (following the new liferay version scheme) I was able to deploy my portlet to Liferay 7.
However I have an issue when I use xhtml templates (cf. ui:decorate) contained in my custom JAR (a web fragment module that regroup all shared code between portlets), resulting to an invalid path error in portlet view. All templates (ui:composition) are in /META-INF/resources/common folder.
Note that /META-INF folder also has a taglib (files are in /META-INF/tags) which I can use without error in my main WAR portlet, as same as custom components (interface/implementation).
I have no clue why it doesn't work anymore because when I was using Liferay 6.2 (GA6) all resources under WAR/WEB-INF/lib/JAR/META-INF/resources were treated like WAR/WEB-INF/resources (cf. Servlet 3.X specification).

EDIT :
I'm able to include templates if I add the javax.faces.FACELETS_RESOURCE_RESOLVER context parameter in the JAR web-fragment.xml (propagated to the web.xml of portlet WAR), pointing to a javax.faces.view.facelets.ResourceResolver implementation. But this is deprecated since JSF 2.2 and I should not use a such directive.

Thank you very much for your help.
thumbnail
7年前 に Juan Gonzalez によって更新されました。

RE: Failed to insert facelets composites from JAR - Liferay 7 GA3

Liferay Legend 投稿: 3089 参加年月日: 08/10/28 最新の投稿
Hi Damien.

In order to get the whole picture, please could you attach a simple portlet to reproduce?

Thanks!
7年前 に Damien Guillermet によって更新されました。

RE: Failed to insert facelets composites from JAR - Liferay 7 GA3

Junior Member 投稿: 44 参加年月日: 15/07/09 最新の投稿
Hello Juan, sure I'll do that emoticon Unless you have any clue with my edit.
thumbnail
7年前 に Juan Gonzalez によって更新されました。

RE: Failed to insert facelets composites from JAR - Liferay 7 GA3

Liferay Legend 投稿: 3089 参加年月日: 08/10/28 最新の投稿
Damien Guillermet:
Hello Juan, sure I'll do that emoticon Unless you have any clue with my edit.


I need more data and a simple portlet that can reproduce the problem will help for sure.

Thanks Damien.
7年前 に Damien Guillermet によって更新されました。

RE: Failed to insert facelets composites from JAR - Liferay 7 GA3

Junior Member 投稿: 44 参加年月日: 15/07/09 最新の投稿
Hello back Juan,

Here are the library and portlet projects in separate archives.
Note that the portlet will work because I added a facelets resource resolver in the library. So you can raise the error by commenting the directive in JAR's web-fragment.xml file.

Let me know I should reduce code more (like maven dependencies/plugins) ;)

Thanks a lot.

EDIT : I modified the structure to match the recommended one. Furthermore I have little troubles with included resources (css, js) via liferay-portlet.xml but we should discuss this later, expect if it's relative to my main issue emoticon
thumbnail
7年前 に Juan Gonzalez によって更新されました。

RE: Failed to insert facelets composites from JAR - Liferay 7 GA3

Liferay Legend 投稿: 3089 参加年月日: 08/10/28 最新の投稿
Thanks very much Damien.

I reproduced this and checking the reasons...

Hope to be back soon.
thumbnail
7年前 に Juan Gonzalez によって更新されました。

RE: Failed to insert facelets composites from JAR - Liferay 7 GA3

Liferay Legend 投稿: 3089 参加年月日: 08/10/28 最新の投稿
Hi Damien.

I am happy to say I already have a fix for this issue, but have to make some checks as it affects how resources are being accesed in Liferay 7.

Will update soon.
thumbnail
7年前 に Juan Gonzalez によって更新されました。

RE: Failed to insert facelets composites from JAR - Liferay 7 GA3

Liferay Legend 投稿: 3089 参加年月日: 08/10/28 最新の投稿
Hi Damien.

Please follow the progress of the fix here: https://issues.liferay.com/browse/LPS-68989
7年前 に Damien Guillermet によって更新されました。

RE: Failed to insert facelets composites from JAR - Liferay 7 GA3

Junior Member 投稿: 44 参加年月日: 15/07/09 最新の投稿
Hello Juan,
thank you very much for your feedback I'll follow this closely emoticon
7年前 に Damien Guillermet によって更新されました。

RE: Failed to insert facelets composites from JAR - Liferay 7 GA3

Junior Member 投稿: 44 参加年月日: 15/07/09 最新の投稿
Thank you for your work on the LPS-68989 issue now resolved ;)
thumbnail
7年前 に Juan Gonzalez によって更新されました。

RE: Failed to insert facelets composites from JAR - Liferay 7 GA3

Liferay Legend 投稿: 3089 参加年月日: 08/10/28 最新の投稿
Damien Guillermet:
Thank you for your work on the LPS-68989 issue now resolved ;)


It's a pleasure Damien. Just double-checked your portlet now renders everything :-D.

Thanks for telling us about this bug and thanks for using Liferay Faces ;-).