I have installed jetspeed and developed a sample portal per studyguides.scja.com site. I could successfully develop and deploy the war file but i am not able to search and add it and see it working. I didnt see any errors on the console.
What tool did you use to develop your portlet? Eclipse? Notepad? IRAD? Lomboz? NetBeans? Just curious.
When you deploy the war file, where do you export it to? When you deploy a JSR-168 portlet to JetSpeed2, you need to drop the portlet war file into the: C:\_jetspeed20\webapps\jetspeed\WEB-INF\deploy directory
Your actual path will depend upon where you installed your portal server.
Now, when I drop the JSR168 Ajax portlet I've been working on, into the deploy directory, I get a whole bunch of output on the DOS prompt/command window that was used to start JetSpeed. When you deploy your own portlet, you should get something similar. Mine says:
Now, I'm not sure when the list of deployable portlets is cached. I sometimes log out of JetSpeed and then log back in again when I'm doing testing to make sure the list of portlets has been regenerated or updated. But give JetSpeed a minute or two to catch up, and you should be able to view your portlet on the list of portlets, and add it to the page.
Oh, by the way, maybe you could show us the portlet.xml file. That's where the name used by the portal to display the name of the portlet to you in the list is configured. If you haven't properly named the portlet in the portlet.xml file, or maybe haven't supported the proper language of your portal server, it might not be displaying the portlet as an option for addition. Make sure the portlet supports your preferred language.
Let me know!
-Cameron McKenzie [ April 08, 2007: Message edited by: Cameron W. McKenzie ]
Joined: Nov 23, 2000
Thanks for your quick reply. Well i didn't put it in deploy folder
Now i can search for the Portlet, but when i add it i am getting the following message ;
Cannot create Portlet instance com.examscam.portlet.HelloWorldPortlet for Portlet Application HelloWorldPortlet
also, please find the portlet.xml: [HelloWorldPortlet sample example from your site.]
This is a simple JSR168 portlet that displays an image. It is uncreatively called ImageDisplayPortlet.
I just want to see if this portlet will deploy and can be added. If it works, then we know the environment works, and things should deploy properly.
One thing I do wonder is if the war file actually contains the compiled portlet class. Open up the war file with WinZip or something, and check to see if the package aware portlet is compiled with the proper name, and is under the classes folder of web-inf. The question is, why can't it create an instance? Maybe the class isn't compiled, maybe the class is incorrectly named, or maybe even, the method signature of the doView method isn't totally 100%.
Maybe you could post the actually Java class you created as well. Lets make sure it extends the GenericPortlet from javax.portlet.
We'll get this working!
Joined: Nov 23, 2000
Thanks for your quick reply.
Deployed ImageDisplayPortlet.war and it clicked , After searching & adding, i cul see the image.
You have previously been warned on one or more occasions regarding adjusting your display name to meet JavaRanch standards. This is not optional. Please take a look at the JavaRanch Naming Policy and adjust your display name to match it prior to your next post.
Your display name must be a first and a last name separated by a space character, and must not be obviously fictitious.
Be aware that accounts with invalid display names are removed.
I'm glad you got it working. I'll dig into that a bit more.
I could not get the above files(std-portlet.tld,portal.tld) getting no network on click of the mentioned links. Please give me alternative links to get the files.
I am getting following error while launching my portlet.
org.apache.jasper.JasperException: The absolute uri: http://java.sun.com/portlet cannot be resolved in either web.xml or the jar files deployed with this application
I have define the below tag in jsp.
<%@ taglib uri="http://java.sun.com/portlet" prefix="p" %>