2 Replies Latest reply on May 14, 2008 12:00 PM by John DeStefano

    Instance Level Portlet Preferences in Mysql

    John DeStefano Apprentice

      Has anyone seen this error when trying to save instance level portlet preferences:

      org.jboss.portal.portlet.InvalidPortletIdException: Cannot configure producer offered portlets

      The problem has also been referenced in the mailing list, but it was not answered:

      http://lists.jboss.org/pipermail/jboss-user/2008-February/112586.html

      We are using a mysql backend.

        • 1. Re: Instance Level Portlet Preferences in Mysql
          Pavel Myshkin Newbie

          Can help you with that error,

          but from my experience with "portlet preferences on instance level" (PPIL) this is very uncomfortable because PPIL are not being persisted correctly and also not being cleared properly when removed which will cause a mess.

          • 2. Re: Instance Level Portlet Preferences in Mysql
            John DeStefano Apprentice

            Ok, here is the problem.

            org.jboss.portal.portlet.InvalidPortletIdException: Cannot configure producer offered portlets
            org.jboss.portal.portlet.state.producer.ProducerPortletInvoker.setProperties(ProducerPortletInvoker.java:538)

            I looked at the ProducerPortletInvoker code and found this:

             //
             if (context.isStateful() == false)
             {
             throw new InvalidPortletIdException("Cannot configure producer offered portlets", portletId);
             }
            

            So I started looking in the database and found JBP_INSTANCE and JBP_PORTLET_STATE. All the new instances that came with the portal worked fine, All the ones I created threw the above exception. The difference was the PORTLET_REF column in the JBP_INSTANCE table.

            Mine had "local.news.RSSNewsPortlet" as the PORTLET_REF, and the default instances had local._7.

            The "7" represents the primary key of the JBP_PORTLET_STATE table.

            So I changed my PORTLET_REF to local._7 and it worked.

            Is this is a bug?

            thanks,