Sunday May 11, 2008
Sunday May 11, 2008
With the announcement of Project WebSynergy, the new web presentation platform for internet and enterprise applications, the excitement is palpable :) The erstwhile portals, will look and feel and more importantly, think (yes think, just wait for Web 3.0 :) ) and act, much better now.
The solution for aggregation and presentation might have been improved with Project WebSynergy, but most of the requirements still remain the same. And one of the main requirements has always been for a good Content Management System (CMS). Project Mirage fulfills this need for Project WebSynergy by providing an Open source CMS built on top of a JSR-170 implementation. This provides portlets which can be deployed on WebSynergy to utilize the CMS functionalities. This screencast tries to showcase a few of the features present.
As of now, things are looking bright :) So download the zip file and try it out. Let us know what you feel about it.
Please feel free to send any feedback on Project Mirage to users@mirage.dev.java.net
Wednesday Mar 12, 2008
Thursday Mar 06, 2008
There has been a long standing requirement to get an Out of the box Content Management System (CMS) and this has been solved by various vendors. But a good open source, standards based implementation which can be used in a Web application, a Portal, a Portlet application or even a command line implementation (yes they have needs too :) ), has been found wanting for some time. So welcome Project Mirage, an Open source CMS which leverages the JSR-170 content repository. This is part of the OpenPortal community.
Project Mirage aims at providing CMS features as services on top of any JSR-170 (JCR) compliant content repository. This right now has an implementation using Apache Jackrabbit, which is the RI for JSR-170. By default, content modeling, versioning, templating using a WYSIWYG editor, access control are some of the services provided in the Project Mirage. Also out of the box, it integrates with SUN JavaCAPS workflow engine so that "Human business workflows" can be associated with contents. SAW is used to ensure that the implementation is not tied to JavaCAPS alone, as SAW provides a layer of abstraction on top of workflow engines.
Look out for more posts on Project Mirage, how to use the API provided, and the default portlets which are built as part of the project.
Friday Aug 10, 2007
The public review draft of JSR 286 was recently released and the related files can be downloaded from this link. One of the major changes introduced in the new Portlet specification is how the caching of markup and resources can be done by the Portlet Container. I just want to highlight the differences between the caching part of JSR 168 and JSR 286 here.
JSR 168:
JSR 286:
The introduction of ETag ensures that the browser can be leveraged to cache resources and markup. With the new features of public sharing of caches, resource caching, validation caching and leveraging browser caching, the performance of aggregation of portlets by a portal can be seen to increase significantly.
Friday Aug 03, 2007
Quite a few people have been posting queries about deploying JSR-168 portlets on the OpenPortal Portlet Container. I would like to elaborate on the various ways to deploy portlets on the OpenPortal Portlet Container now. Before you read further, you would need the OpenPortal Portlet Container to be installed. The installation instructions on the site are quite easy to follow and you should be up and running in a few minutes.
There are now officially 3 different ways to deploy a JSR-168 portlet on the OpenPortal Portlet Container:
1. Portlet Container Driver "Admin" tab:
After installing the Portlet Container, you can access the Portlet Container Driver at http://localhost:8080/portletdriver/dt (assuming default values for the host and server port). To deploy a portlet follow these steps :
Please note that a successful deployment means that the Portlet Container has been able to register the details, but it would take a brief amount of time for the war to be deployed on to the application server (based on the time in seconds set for the auto deployment to kick in. By default this is small, and it should be done in 3-5 seconds).
2. ANT task / CLI
An ANT task is provided, for command line interface, to deploy portlets. You can invoke this task and pass the various parameters expected and the deployment will be done in a jiffy :). The following commands do the trick:
- cd $PC_INSTALL_DIR/bin (PC_INSTALL_DIR = GLASSFISH_HOME/domains/domain1/portlet-container)
- ant -Dportlet-war=<portlet-war-file-path>deploy-portlet
Well that's that really!
3. Auto-deploying portlets
This is the easiest option of the three to use. Just copy your portlet war file to the $PC_INSTALL_DIR/autodeploy directory. As simple as that, and it will deploy your portlet! Please make sure that the server is running :)
So go ahead create those portlets (check out the Portal Pack Project for really cool and easy to use Netbeans plugin for creating Portlets) and deploy it on the OpenPortal Portlet Container and start using them.
PS: There is another way to deploy your portlets using Netbeans, and it is part of the Portal Pack Project and the site has screencasts on using the plugin to develop and deploy portlets.
Saturday Jun 09, 2007
Browser caching has been taken for granted for so long, that I had not had an opportunity to explore it. Recently, I went through it for leveraging the cache of the browser and I want to put together the findings here :
Expiration caching -
The browser caches contents of a page (with the key as the url) for a predefined amount of time, which is indicated in the HTTP Response headers. After this time the browser sends a request to the server, to check for fresh contents.
Validation caching -
With HTTP 1.1 a new tag called the Entity Tag (ETag) is introduced, which is opaque to the browser (i.e., just stored by the browser). The browser does not do anything with the ETag but just sends the value as "If-None-Match" HTTP Request header. The server can utilize the ETag by sending a value which identifies the contents of a page, for instance, the userId so that the cache is valid for the user's session. On receiving the ETag value in the "If-None-Match" header, the server can validate whether the contents in the browser cache are still valid, for instance, now the server knows that the user has logged out, and so the cache is invalid, and the fresh contents can be sent back.
The typical steps involved are :
Tuesday May 08, 2007
The long standing debate of Ruby on Rails vs. JavaEE applications will continue to stand for some time. But I believe in the notion of "If you can't fight them, join them". So Ruby guys, here is some good news for you. The OpenPortal Portlet Container Project will soon support Ruby on Rails applications so that they can be treated on par with the JSR-168 portlets. So whether you are writing a Java portlet or a Ruby on Rails application, you can aggregate them using the OpenPortal Portlet Container.
The ROR application is treated as a first class citizen by the OpenPortal. A new container implementation is provided so that the ROR application can be invoked by the OpenPortal. A ROR application can now be bundled in a Web Application Archive (war) due to the efforts of the Rails Integration project. To enable ease of use and minimal knowledge of Java/JavaEE a plugin on Netbeans 6 is developed. Netbeans 6 supports Ruby on Rails application development. The new plugin leverages the same so that with a few clicks a war which the OpenPortal Portlet Container can recognize.
The screen cast for the development of the Ruby on Rails portlet can be found here. The screen cast shows how one can deploy and aggregate the now famous simple ROR blog application into the OpenPortal Portlet Container.
If you are at JavaOne make sure that you check out the Sun's Portal booth where there are live demos of the same on display. So pretty soon you will be able to write your ROR application knowing that there is a Java Portal capable of aggregating your application with other java portlets, and sleep peacefully. :)
PS: If you are going to the JavaOne booth then say hi to Sandeep Soni who has contributed in a major way to get the ROR application in the OpenPortal Portlet Container project.
Monday Mar 26, 2007
It has been an exciting week, with the prospect of integrating and running a Ruby on Rails application as a Portlet. As any Ruby fan would know, it is very easy to generate a web application on Rails with a few commands. So the next logical step was to see if we can somehow get a Portlet out of this web application. JRuby is a wonderfully powerful java implementation of Ruby and the Rails-integration project, which is a JRuby extras project helps in the integration of a Rails application with a Servlet container.
There is a plugin provided by the Rails integration project, which creates a war out of a Rails application. This war can be deployed on say Glassfish as a web application and can be used as any normal Java EE web application. For more details of how to do this, check out Ashish's blog entry.
So it appeared that there was an existing way to get a Java EE web application. So we used the Portal pack Netbeans plugin to create a Portlet application. We then made sure that the appropriate doXXXX() methods did a Request Dispatch to the rails application by providing the url of the controller and action needed to perform. For instance, using the famous Cookbook Ruby on Rails application, the doView() would be appropriately taking the user to the list of Recipes and so on. As of now this seems to work fine. This is still work in progress, but the presence of JRuby and Rails-integration projects has made the creation of a Portlet a lot easier. Right now this has been working on the Open Source Portlet Container on java.net.
Next steps would be :
Monday Jan 22, 2007
The Enterprise class Portlet Container can now be installed and used with Tomcat. The installation instructions are available on the site and can be accessed at this link. Please try it out. If you face any problems do let us know.
Friday Dec 15, 2006
There is a new plugin on the block for Netbeans 5.5 and it rocks! The Portlet plugin for Netbeans allows you create new Portlets with just a few clicks and deploy the Portlet on the Enterprise class Portlet Container which is now part of the Java Application Platform SDK Update 2 which you can download here. The Netbeans plugin is available for download here. The usage of the plugin is very well illustrated in flash demos at http://portalpack.netbeans.org/. Please check out Satya's blog for more details.
So all the questions on Hello World portlets should be categorically answered by using the plugin!
The Enterprise Class Portlet Container on java.net is available as part of the Java Application Platform SDK Update 2. You can download the App SDK at this link. The Portlet Container can be accessed on java.net here. Right now kudos is in order for the portlet container team for a great job!
Please check out Deepak's blog providing details of the same.
Tuesday Dec 05, 2006
The open source implementation of WSRP v1 by Sun is now available for Windows as well. Please check the WSRP Milestone1 Preview here. The installation instructions are the same for Windows and Unix platforms. The Portlet Container works on Windows already, and that should not be a problem either. Again, the installation instructions for the Portlet container remain the same as that on non-windows platforms.
So if you are using a Windows box and have been shying away from checking out the WSRP implementation, here is your opportunity to play with it :) If you do have any issues please let us know at users@wsrp.dev.java.net .
Tuesday Nov 28, 2006
Anyone who has tried to use any WSRP implementation would know how difficult it is to get something working! So here is something simple to appease the famished.
Sun's Open Source WSRP Project at java.net provides the implementation of the WSRP 1.0 specification and runs on Sun's Open Source Portlet Container. The instructions on the WSRP project site are detailed and are in easy to understand and use steps. Please follow the instructions to get the source, compile and create a distribution. Once you have the distribution, to administer and manage the WSRP Producer and Consumer, two administration portlets are provided with the source, which are built along with the other sources.
Please ensure that JAVA_HOME is set to jdk 1.5 home as the admin server uses the platform MBean server to register the MBeans required for administration and management of WSRP Producer and Consumer. Follow the below steps to get your administration portlets up and running.
Start the Admin server:
This will start the admin server and create a producers.xml file in the data storage directory specified in <wsrp-directory>/dist/wsrp/config/deployenv.conf and also a consumer.xml file containing the default information.
Deploy the Admin portlets:
Use the Admin Portlets:
That's all there is to it really. The number of steps may seem to be overwhelming, but it is very easy to follow and will indeed get you up and running very quickly. Try it out and if you have any doubts, concerns, comments or downright criticisms please feel free to let us know at users@wsrp.dev.java.net.
Rock on. :)
Monday Nov 27, 2006
It gives me great pleasure to write about the fact that the WSRP 1.0 open source implementation by Sun is out for preview. The project can be accessed at https://wsrp.dev.java.net.
The documentation of how to get this working on the Sun's open source Portlet Container is present on the site. Please feel free to download the code and use it. If you do have any problems, please let us know at users@wsrp.dev.java.net and we will be more than happy to help you out and take your feedback.
But for now, this is a time to cherish for the WSRP team. Team lets a take a bow :)
Thursday Sep 21, 2006
If you have already installed Sun Open Source Enterprise Class Portlet Container and want to deploy your portlets and test them, you can do so quite easily. Right now, Sun Portlet Container comes with tasks for deploying portlets when the Portlet Container is deployed on GlassFish. To deploy the Sun Portlet Container on GlassFish, please check out my previous blog entry.
If you have built the portlet container, then a dist/portlet-container directory would be created containing among various directories, a bin directory. I'll refer to this dist/portlet-container as PORTLET_CONTAINER_HOME.