2 Replies Latest reply on Jun 29, 2007 4:21 AM by rekrevs

    Deployed portlet not found in personal dashboard editor

    rekrevs

      Hi!

      I have created a basic portlet using netbeans 5.5.1 with portal-pack-plugin-1_2 and I use JDK 1.5.

      I managed to build the project with netbeans and created the .war file. Then I copied the .war file into the deploy folder on my Jboss portal on the server. This seems to work fine. It looks like this in the server log:

      15:39:45,971 INFO [TomcatDeployer] deploy, ctxPath=/NuFunkarDet, warUrl=.../tmp/deploy/tmp4724NuFunkarDet-exp.war/

      The problem is:
      When i log on to the server with admin accont and want to add my portlet into the portal in the personal dashboard editor. I can´t find it in the selection of avalible portlets.

      Anyone that knows what´s wrong?

      Here is the code:

      ***NuFunkarDet.java***

      package org.jboss.portlet;
      import javax.portlet.GenericPortlet;
      import javax.portlet.ActionRequest;
      import javax.portlet.RenderRequest;
      import javax.portlet.ActionResponse;
      import javax.portlet.RenderResponse;
      import javax.portlet.PortletException;
      import javax.portlet.PortletURL;
      import javax.portlet.PortletMode;
      import javax.portlet.PortletPreferences;
      import javax.portlet.WindowState;
      import java.io.IOException;
      import java.io.PrintWriter;

      public class NuFunkarDet extends GenericPortlet {

      public void processAction(ActionRequest request, ActionResponse response) throws PortletException,IOException {

      }
      public void doView(RenderRequest request,RenderResponse response) throws PortletException,IOException {
      //Uncomment below lines to see the output
      response.setContentType("text/html");
      PrintWriter writer = response.getWriter();
      writer.println("View Mode");
      }

      }



      ***Portlet.xml***

      <?xml version="1.0" encoding="UTF-8"?>
      <portlet-app xmlns="http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd/etc/opt/SUNWportal/dtd/portlet.xsd" version="1.0">



      NuFunkarDet
      <portlet-name>NuFunkarDet</portlet-name>
      <display-name>NuFunkarDet</display-name>
      <portlet-class>org.jboss.portlet.NuFunkarDet</portlet-class>
      <expiration-cache>0</expiration-cache>

      <mime-type>text/html</mime-type>
      <portlet-mode>VIEW</portlet-mode>

      <portlet-info>
      NuFunkarDet
      <short-title>NuFunkarDet</short-title>
      </portlet-info>

      </portlet-app>


      ***web.xml***


      <?xml version="1.0" encoding="UTF-8"?>

      <web-app xmlns="http://java.sun.com/xml/ns/j2ee"
      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"
      version="2.4">


      </web-app>



      ***context.xml***

      <?xml version="1.0" encoding="UTF-8"?>