Hi all,

some time ago there was a lot discussion about problems with the beginners 
HelloWorldPortlet. Even though recommended to put the class file into the 
Web-inf/classes directory, this didn't work for us. However, we found a solution, 
which we like to share. If there are other prossibilities, please let us know.

We run Jetspeed 1.3a1 under WinNT. The trick is, to make a module and than a jar file, 
which can be put in the jetspeed/lib directory as there also the jetspeed.jar resides.
But step by step:

Portlet installation or
How to solve java.lang.ClassNotFoundException 


Step by step solution:


1. Develope your portlet with a package identifier (important!).

>> package myPortlet; // just as an example name
  
   import org.apache.jetspeed.portal.portlets.AbstractPortlet;
   import ...
  
   public class newPortlet extends AbstractPortlet
   {
     ...
   }
  

2. Make a jar file (assuming that you have a myPortlet directory which contains 
newPortlet.class):

   c:\jar cvf myJar.jar myPortlet
   

3. Copy myJar.jar into your jetspeed/web-inf/lib directory


4. Open the jetspeed configuration file 'TurbineResources.properties' and add your 
package (myPortlet)
   in the 'Modul Packages' section (obviously you cann add all your privte protlets 
into this module):
   
   module.packages=myPortlet;org.apache.jetspeed.modules,...


5. Open the jetspeed registration file 'jetspeed-config.jcfg' and add your Portlet:

   <portlet-entry type="instance" name="newPortlet" hidden="true">
     <classname>newPortlet</classname> 
   </portlet-entry>

6. Restart 'tomcat' and 'jetspeed', that's all!
 

Gr�sse/Best Regards

J�rgen Riedl

*
Juergen Riedl                  

SIEMENS ICM S CP PE
Geisenhausenerstr. 15, 81379 Muenchen, Germany
Site: MchH/Ge15, Building 18600, Room 440
Solutions Architect, Customer Projects, mtroop
voice:  (+49)-(0)89-722-42004    /      fax: (+49)-(0)89-722-54725
mobile:(+49)-(0)170-63 23 413   /      email: [EMAIL PROTECTED]
*
"The future masters of technology will have to be lighthearted and
intelligent. The machine easily masters the grim and the dumb." 
-- Marshall McLuhan



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to