7
votes

I´m developing an application for Liferay 6.1 EE GA3.

Under the control panel, we have the section Private plugin installer where we can install / deploy new portlets. I was using the panel and the section was workng correctly.

Then i tried to install a custom portlet. For some reason the installation failed and i removed the portlet from the "deploy" folder and i even restarted the server. This portlet don´t do anything very special, it just runs some custom queries against Liferay´s Lucene search engine.

And then, after this process, the section "Server > Plugins installation > Private plugin installer" kind of "disapeared" from my screen.

Below are the screens that i see when i acess the sections "Server > Server Administration" and "Server > Plugins installation" (you can see that it appears empty, without the link for the Private Plugin installer):

Screenshot 1: Server > Server Administration (showing an empty screen)

enter image description here

Screenshot 2: Server > Plugins installation (showing an empty screen)

enter image description here

Here is the screen where you can see that my user has all the necessary administrative permissions to install plugins:

Screenshot 3: My user profile and permissions enter image description here

In the screen below you can see that the Private Plugin installer Hook is installed in the webapps folder (in fact it already was installed all the time) as are some others hooks, themes and portlets:

Screenshot 4: Tomcat´s webaaps folder enter image description here

Here is the content of the /html/portlet/admin/view.jsp and /html/portlet/admin/view.portal.jsp (with the initial comments removed from the code). Those files were not manually edited.

Content of /html/portlet/admin/view.jsp

<%@ include file="/html/portlet/admin/view.portal.jsp" %>

Content of /html/portlet/admin/view.portal.jsp

<%@ include file="/html/portlet/admin/init.jsp" %>

<c:choose>
    <c:when test="<%= permissionChecker.isOmniadmin() %>">

        <%
        String tabs1 = ParamUtil.getString(request, "tabs1", "server");

        boolean showTabs1 = false;

        if (portletName.equals(PortletKeys.ADMIN_INSTANCE)) {
            tabs1 = "instances";
        }
        else if (portletName.equals(PortletKeys.ADMIN_PLUGINS)) {
            tabs1 = "plugins";
        }
        else if (portletName.equals(PortletKeys.ADMIN_SERVER)) {
            tabs1 = "server";
        }
        else if (portletName.equals(PortletKeys.ADMIN)) {
            showTabs1 = true;
        }

        String tabs2 = ParamUtil.getString(request, "tabs2");
        String tabs3 = ParamUtil.getString(request, "tabs3");

        if (tabs1.equals("plugins")) {
            if (!tabs2.equals("portlet-plugins") && !tabs2.equals("theme-plugins") && !tabs2.equals("layout-template-plugins") && !tabs2.equals("hook-plugins") && !tabs2.equals("web-plugins")) {
                tabs2 = "portlet-plugins";
            }
        }

        int cur = ParamUtil.getInteger(request, SearchContainer.DEFAULT_CUR_PARAM);
        int delta = ParamUtil.getInteger(request, SearchContainer.DEFAULT_DELTA_PARAM);

        PortletURL portletURL = renderResponse.createRenderURL();

        portletURL.setParameter("struts_action", "/admin/view");
        portletURL.setParameter("tabs1", tabs1);
        portletURL.setParameter("tabs2", tabs2);
        portletURL.setParameter("tabs3", tabs3);
        %>

        <portlet:renderURL var="redirectURL">
            <portlet:param name="struts_action" value="/admin/view" />
            <portlet:param name="tabs1" value="<%= tabs1 %>" />
            <portlet:param name="tabs2" value="<%= tabs2 %>" />
            <portlet:param name="tabs3" value="<%= tabs3 %>" />
            <portlet:param name="cur" value="<%= String.valueOf(cur) %>" />
        </portlet:renderURL>

        <aui:form action="<%= portletURL.toString() %>" method="post" name="fm">
            <aui:input name="<%= Constants.CMD %>" type="hidden" />
            <aui:input name="tabs1" type="hidden" value="<%= tabs1 %>" />
            <aui:input name="tabs2" type="hidden" value="<%= tabs2 %>" />
            <aui:input name="tabs3" type="hidden" value="<%= tabs3 %>" />
            <aui:input name="redirect" type="hidden" value="<%= redirectURL %>" />
            <aui:input name="portletId" type="hidden" />

            <c:if test="<%= showTabs1 %>">
                <liferay-ui:tabs
                    names="server,instances,plugins"
                    url="<%= portletURL.toString() %>"
                />
            </c:if>

            <c:choose>
                <c:when test='<%= tabs1.equals("server") %>'>
                    <%@ include file="/html/portlet/admin/server.jspf" %>

                    <aui:script use="liferay-admin">
                        new Liferay.Portlet.Admin(
                            {
                                form: document.<portlet:namespace />fm,
                                namespace: '<portlet:namespace />',
                                url: '<portlet:actionURL><portlet:param name="struts_action" value="/admin/edit_server" /></portlet:actionURL>'
                            }
                        );
                    </aui:script>
                </c:when>
                <c:when test='<%= tabs1.equals("instances") %>'>
                    <%@ include file="/html/portlet/admin/instances.jspf" %>
                </c:when>
                <c:when test='<%= tabs1.equals("plugins") %>'>

                    <%
                    PortletURL marketplaceURL = null;

                    if ((PrefsPropsUtil.getBoolean(PropsKeys.AUTO_DEPLOY_ENABLED, PropsValues.AUTO_DEPLOY_ENABLED) || PortalUtil.isOmniadmin(user.getUserId())) && PortletLocalServiceUtil.hasPortlet(themeDisplay.getCompanyId(), PortletKeys.MARKETPLACE_STORE)) {
                        marketplaceURL = ((RenderResponseImpl)renderResponse).createRenderURL(PortletKeys.MARKETPLACE_STORE);
                    }

                    boolean showEditPluginHREF = false;
                    boolean showReindexButton = true;
                    %>

                    <%@ include file="/html/portlet/plugins_admin/plugins.jspf" %>
                </c:when>
            </c:choose>
        </aui:form>

        <aui:script>
            function <portlet:namespace />saveServer(cmd) {
                document.<portlet:namespace />fm.<portlet:namespace /><%= Constants.CMD %>.value = cmd;
                document.<portlet:namespace />fm.<portlet:namespace />redirect.value = "<portlet:renderURL><portlet:param name="struts_action" value="/admin/view" /><portlet:param name="tabs1" value="<%= tabs1 %>" /><portlet:param name="tabs2" value="<%= tabs2 %>" /><portlet:param name="tabs3" value="<%= tabs3 %>" /><portlet:param name="<%= SearchContainer.DEFAULT_CUR_PARAM %>" value="<%= String.valueOf(cur) %>" /><portlet:param name="<%= SearchContainer.DEFAULT_DELTA_PARAM %>" value="<%= String.valueOf(delta) %>" /></portlet:renderURL>";
                submitForm(document.<portlet:namespace />fm, "<portlet:actionURL><portlet:param name="struts_action" value="/admin/edit_server" /></portlet:actionURL>");
            }
        </aui:script>
    </c:when>
    <c:otherwise>
        <liferay-util:include page="/html/portal/portlet_access_denied.jsp" />
    </c:otherwise>
</c:choose>

Thanks for your attention

3
The first screenshot shows the "Server Administration" screen. At least in 6.1 CE GA3, the Private Plugin Installer is listed in the "Plugins Instalation" section. Is it not found there? If no, could you give us the path of the URL (e.g. /group/control_panel/manage?p_p_id=136&p_p_lifecycle=0&p_p_state=maximized&p_p_mode=view&doAsGroupId=10179&refererPlid=10613) to both the Server Administration and Plugins Instalation screens?brandizzi
the "Plugins Instalation" section is there...... i have added the wrong screenshot.... i´m going to update the question, thanks for your observation :-)Marcelo Bezerra bovino
Now that's fishy! Isn't there some error messages in the logs?brandizzi
Yes, this seems very funny and fishy =D One hypothesis is that this is somehow related to this: issues.liferay.com/browse/LPS-29039 I havent been able to spot anything useful in the logs yet (the catalina.out has a little more than 4GB in size)Marcelo Bezerra bovino
Also appears to be related to: issues.liferay.com/browse/LPS-29765Marcelo Bezerra bovino

3 Answers

0
votes

I'm not really sure what happens, but a few thoughts based on your description and the comments listing some issues:

  • You might want to install the Private Plugins Installer from marketplace, potentially updated from the version that you are running
  • In case there's an overlapping (conflicting) view.jsp, you might want to backport this ext plugin to 6.1 and flag conflicting overrides. In case you already had conflicts, you'll have to restore the original jsp as it might have been deleted during deployment of the conflicting hooks.
  • As you state these problems are on Liferay EE, opening a support ticket will most likely help you - that's what this is for
  • If your logfile is too huge to be meaningful: Check if it's going back to ancient times, e.g. maybe you only need the last few kilobytes. In that case: Shorten it and set up logrotation. If all of the Gigabytes are generated recently, you either are logging way too much or you have some problems that you should fix sooner rather than later.
0
votes

Try cleaning the temp and work folder of your server. That might help!!

0
votes

I had already given up on solving this, but i managed to make this work.

I was developing a portlet that manipulate and search content (from Liferay Document Library) with Lucene and because of that, i stoped and restarted my Liferay instance with the following line uncommented in portal-ext.properties

index.on.startup=true

And to my surprise, after all the portal content have been reindexed and the startup process was finished the links "Server > Server Administration", "Server > Plugins installation" and the Private Plugin installer were working again. I will not lie: i dont know why "index.on.startup=true" solved this. If somebody has some idea or theory about it, i would be glad to hear it. Thanks for your help.