Monday, December 1, 2014

Portlet: Deploy Portlet (JSR 286) using JDEV

In this blog we are going to deploy our previously created portlet  ( here ) and view its output

We are going to deploy our portlet in weblogic which is WSRP producer also. It means it can expose our JSR 286 based portlet as WSRP 2.0.
WSRP is web service for remote portlet. If we expose our JSR 286 portlet as WSRP 2.0 then our portlets can be used not only in java portals but in any other portasl (.NET) based etc.

To expose your portlet as WSRP we can follow these steps.
1. Create connection to weblogic server on Resource Pallete. 
   (I have a stand alone weblogic server running locally in my jdev and I would be deploying my portlets on it)

     As we are deploying on stand alone server it must behave as a portlet producer. For that we need to extend weblogic with 'Oracle Portlet Producer' as shown below



2. Create deployment profile:
      a. Select project properties > Deployment > New
                   
      b. Provide Archive Type (war) and name for deployment profile
      c. Just say OK in war profile


3. Deploy war:
     a. Right click on project and select Deploy and then deployment profile
    
      b. Select 'Deploy to Application Server option'
      c. Select your server on which you want to deploy
      d. Select 'Yes' for WSRP option

Once deployment is successful, you will see a url like

http://<server:port>/<context-root>


 Now launch that url on a browser
Page provides a url 'WSRP v2 WSDL'. This url points to a WSDL, which exposes all portlets of application using a WSDL. We need this URL to test this portlet.
====================================================================

If we want to deploy it on integrated server, we can start integrated server and then deploy using a deployment profile as suggested above.
But to test it we need to run integrated server from the application which has portal page. As we can only have one integrated server running at a time I would suggest following steps

1. Create a new ADF application.
2. Start Integrated server when this new application is selected.
3. Open JSR 286 application and deploy it on already running integrated server.
4. Again open ADF application and create WSRP connection with deployed JSR286 application.
5. Create a page in ADF application and drag and drop portlet from connection on page directly.

We will test deployed portlet in our next blog.






2 comments:

nhuthuy said...

Thanks for sharing, nice post! Post really provice useful information!

An Thái Sơn chia sẻ trẻ sơ sinh nằm nôi điện có tốt không hay võng điện có tốt không và giải đáp cục điện đưa võng giá bao nhiêu cũng như địa chỉ bán máy đưa võng ở đâu uy tín.

Muhammad Azwar said...

Nice Article, thanks for this information
Also check this out
Laptops, Mobiles, Games, Tv, Smartwatches etc Daily Tech News Updates.