Wednesday May 14, 2008

Extending Project WebSynergy's Tables

Project WebSynergy 

We had recently started work on semantic enabling Project WebSynergy's community feature.

Read my blog on that.

For doing this we had to extend the existing table structure by adding new columns
and  also creating new tables.

In this blog I will show how easy it is do this using
Project WebSynergy's ServiceBuilder framework 

The use case for this example will be to add an ontologyId column
to the existing BlogsEntry table.
We would also create a new BlogsEntryOntologyMapping Table. 

Open the
<synergy-workspace>\\e2demo\\synergy\\liferay\\patch\\portal-impl\\src\\com\\liferay
\\portlet\\blogs\\service.xml

in your favorite IDE (we would recommend NetBeans)

Each <entity> tag corresponds to a table in the DB.

To add "OntologyId" column to the BlogsEntry table
add the following in <entity name="BlogsEntry"> </entity> tag

<column name="ontologyId" type="String" />

We can also add a finder method corresponding to the column that we have just added.
Using this the callers can get the blog entries corresponding to an ontologyId.

        <finder name="OntologyId" return-type="Collection">
            <finder-column name="ontologyId" />
        </finder>
This would generate a findByOntologyId() in the BlogsEntryPersistence
and BlogsEntryPersistenceImpl.

To add a new BlogsEntryOntlogyMapping table add the following 

 <entity name="BlogsEntryOntlogyMapping" local-service="true" remote-service="true">
        <column name="entryId" type="long" primary="true" />
        <column name="ontologyId" type="long" />
    </entity>

Next we need to add getBlogEntriesByOntologyId() to the BlogsEntryLocalServiceImpl class.

public List getBlogEntriesByOntologyId(String ontologyId) throws SystemException{ 

             List blogtnriesList = blogsEntryPersistence.findByOntologyId(ontologyId);

return blogtnriesList;

You will get a compilation error on the blogsEntryPersistence.findByOntologyId(ontologyId) line.
This is because the method is still not added to the BlogsEntryPersistence interface.

But dont mind that as of now :)

After making these changes,
cd to <synergy-workspace>\\e2demo\\synergy\\liferay\\portal\\portal-impl
in the command prompt and run the following ant script.

ant build-service-portlet-blogs 

This generates all the service, util, persistence and  factory classes that are relevant to Blogs.

Open the <synergy-workspace>\\e2demo\\synergy\\liferay\\portal\\portal-service\\src\\com\\liferay\\portlet\\blogs \\service\\persistence\\BlogsEntryPersistence, you will find that the findByOntologyId() is newly generated.

Open the <synergy-workspace>\\e2demo\\synergy\\liferay\\portal\\portal-service\\src\\com\\liferay\\portlet\\blogs\\ service\\BlogsEntryLocalService and BlogsEntryLocalServiceUtil, you will find that the getBlogEntriesByOntologyId() is newly generated.

Now you can call the BlogsEntryLocalServiceUtil .getBlogEntriesByOntologyId() from any portlet class or jsp,
you will get the blog entries that the specific ontologyId applied to that.

Next the changes have to be made in the db scripts.

For this run ant build-db in the command prompt that you opened before.

Open the <synergy-workspace>\\e2demo\\synergy\\liferay\\portal\\sql\\portal-tables.sql and <synergy-workspace>\\e2demo\\synergy\\liferay\\portal\\sql\\create-\*.sql.

You will find that the scripts have been suitably modifled.

For the changes to be reflected on the DB (could be MySQL, HSQL, etc),
drop the existing tables under lPortal database if any, and re-start the server.
The ontologyId column would be added to the BlogsEntry Table and BlogsEntryOntologyMapping table would have been created.

Extending Project WebSynergy's tables is as simple as this. You can extend this example to any other feature like wiki, bookmarks, etc.

 


Sunday May 11, 2008

Semantic Community Portal in Project WebSynergy

   WebSynergy

 Semantic Web

The community feature of Project WebSynergy has been semantically enabled. This is a preview version of that.
This is taking the first step towards Web3.0 enablement.

So whats the Semantic Web ??
The semantic web is an evolving extension of the world wide web, in which web content can be expressed not only in a natural language but also in a format that can be read and used by machines for processing the information. It is w3c recommendation.

As a human when we write and read a blob of text, we know what it means but a machine reading a bunch of characters has no idea as to what it means. 

For the machine to be as intelligent as humans to decipher similar information from the text, there has to be some kind of information that the machine has to be provided with. This "extra" information is traditionally provided as meta-data in the form of tags, microformats or some other means. A much more structured and scientific way of applying metadata to a blurb of text is via what is called an ontology.

The community feature of Project WebSynergy allows you to add blog entries, wiki pages and message boards.

Refer to my blog on how to create a community in Project WebSynergy.
For an idea of what a Semantic Community Portal is, see here.

In a Project WebSynergy community, when the user creates a blog entry or a wiki page, he/she can optionally associate it with an ontology element (which acts as the metadata).
When the user views the blog entry, the other semantically related blog entries and wiki pages are displayed. The search for the related entires is not a key word search, but a semantic search done by the reasoner. The semantic reasoner infers the related ontology elements and we can see the blog entries and wiki pages for which  the related ontology elements have been applied to.

An example of the Semantic Community Portal is shown in the screen-casts.

Wednesday Jul 25, 2007

Developing JSF Portlets with NetBeans Visual Web Pack & Portal Pack Plug-in

The NetBeans Visual Web Pack helps developers create JSF based web application using drag and drop support for JavaServer Faces components. The current version of Visual Web Pack doesn't have support for JSF based Portlet Applications. Most probably this functionality will be addressed in the future version of Visual Web Pack. But many users who have been migrating from Sun Studio Creator to NetBeans 6.0 are asking about this feature in various forums. So I spent some time to find out if it's possible to build JSF Portlet with the current version of Visual Web Pack and Portal Pack plug-in.

With a few manual steps you can actually get JSF Portlet Builder functionality using NetBeans Visual Web Pack and Portal Pack Plug-in togather. For more details read here

Monday Jul 23, 2007

How about a Semantic Community Portal?

A lot of research currently is going on in the space of the currently evolving Semantic Web. Also a good deal of work has gone in the recent past in building social networking web portals. There seemingly is a synergy between the social networking community portals and the semantic web. For a more detailed view on these thoughts view my blog entry here.

Thursday Jul 19, 2007

Command-Line Utilities to Administer Communities

Portal Server community administration can be done from either the Portal Server Management Console or through command-line interface (CLI). 

For the Portal Server 7.1u1 release, the command-line utilities for community administration was consolidated into a technical note.

 Each entry has the command (long and short formats), description, syntax, and options.

Instructions to administer communities from the Portal Server Management Console is available in the online help.

Tech Article on Web Services for Remote Portlets

 

 

 

A technical article is now available in BigAdmin on administering Web Services for Remote Portlets (WSRP) for Sun Java System Portal Server 7.1 written by Sunil Bhaskaran. You can also find this information in a WSRP chapter in the Sun Java System Portal Server Administration Guide.

Another technical article by Rajesh Thiagarajan and Marina Sum, in a four part series titled Open-Source Portal Initiative, "describes the WSRP Project's system and deployment architectures, its build and deployment processes, and the procedure for creating remote portlet windows."

Wednesday Jul 18, 2007

The Design Story: Yesterday, Today...

 [Click image to see enlarged view]

The past two iterations of work on the Portal Server Admin console have been an interesting journey in design work.

We started by teasing the Portal Server Console out of the Identity Console. Endless meetings with white boards filled with diagrams of everything that needed to be presented to the user in the console, and how they should be grouped. Denim was my friend those days. At the end of all this we had a spanking new console with a navigation scheme that had a good amount of "scent". What is scent you say? It is a concept that Jared Spool uses, and that I happen to like. The idea is that a well designed website should let users know that they are on the right track. The 7.0 console had the ability to lead you to the area that you wanted to go, and to find your way back there with ease the next time you wanted to.

The next iteration of work was adding the Visual Display Design Tool. A Direct Manipulation Interface that lets the Administrator interact directly with what they are working on - a portal page. This advances the UI further along the continuum of task awareness (note: I did not say task based, task centric etc.. I should blog sometime about my reasons for avoiding those terms...). One of the unique tools in this round of work was comics to tell stories. It was a lot of fun to do, and was a lot more effective in ensuring a shared understanding of the work. Plus it was a lot of fun to put together!

Cross Posted from : http://blogs.sun.com/realDesign/

Tuesday Jul 17, 2007

Browser Testing Nirvana

IE6, IE7, Safari, Firefox

As part of the OpenPortal project we strive to make the UI as visually appealing as possible and Portal Server 7.2 is full of advancements in this area.  Why?  We want you to touch it, feeling connected to your portal services.

That means we do a ton of browser testing via our great QA team to ensure our UI is consistent across browsers.

And now thanks to Parallels with Coherence,  UI development and testing should be a whole lot easier.  With it, I can run all the major browsers simultaneously and see changes instantly without switching machines/keyboards.

Just one small thing we do to help ensure a better user experience for you. 

Monday Jul 16, 2007

Portal Server 7.2 Build B5 available

 OpenPortal Mascot

Portal Server 7.2  Build 5 is now available in the OpenPortal project.

Highlights of this build are support for Sun Application Server 9.1, GlassFish V2, integration with SAW, Mirage, AES encryption for SRA,  new consolidated sampleportals and much more.

Checkout Getting started with OpenPortal and follow the Install Instructions and Release notes to try the latest B5 build.

Thursday Jul 12, 2007

Blog maintenance: Updated tag cloud

Blog maintenanceQuick FYI -- The tag cloud / top tags section on the blog has been moved to the top on the right nav bar. Also, the tags for each entry on the blog have been reviewed and refreshed. We hope that the tags now better serve locatability of the desired topic/content. 

Any comments/suggestions to further enhance the experience on this blog most appreciated.

Tuesday Jul 10, 2007

JSF Portlet Bridge 1.2.1 and 1.1.5 released

We've released JSF Portlet Bridge 1.2.1 and 1.1.5. The changelog contains issues resolved as well as any new features added.

If you find any issues or have any feedback for features, etc., please let us know!

To know more about JSF Portlet Bridge, you can read the article JavaServer Faces Technology-Based Portlet Bridge

Ohloh tracks OpenPortal project

Ohloh The OpenPortal project has an entry on the Ohloh web site for tracking information related to the OpenPortal community. This includes information about committers, code size and makeup, and licensing. If you use software from any of the OpenPortal projects, please add OpenPortal to your stack on Ohloh. We would also welcome any user reviews.

Monday Jul 09, 2007

Industry Spotlight: Portlets Yahoo! Group

Click here to join portlets
Click to join portlets

If you are a portlet developer and/or user (or for that matter, in the business of building and/or using the infrastructure that serves as the runtime environment for portlets and more, i.e. portal servers) and are not aware of the Portlets Group at Yahoo!, you should consider checking it out.

The description on the group site states "This group is created with the objective of discussing portlets and related technology, their usability and problems associated with them. Portlets related technologies, standardizations and specifications like JSR 168, Web Services for Remote Portlets (WSRP), and JSR 170 (JCR) are some of the discussion issues. Though there is no restrictions, you can discuss anything related to portlet..", as well as "..Popular open source and commercial portal servers can also be discussed here..".

The group was founded in November 2003 and today has an impressive membership roster of 5800+ individuals.

Friday Jul 06, 2007

Screencast: Syndication of Portlets and iGoogle Gadgets

Here's a new screencast that demonstrates the syndication of Google gadgets from iGoogle to the Sun Portal Server, and also syndication of portlets/channels from the Sun Portal Server to iGoogle. The gadgets are syndicated with the help of the open source Google gadgets wrapper portlet from PALAB. The content from Sun Portal Server is syndicated to iGoogle using a Javascript/AJAX script as discussed in a previous post

Thursday Jul 05, 2007

Sun Portal in 2007 SYS-CON SOA World Reader's Choice Awards

SYS-CON SOA World Reader's Choice Awards

Sun Java System Portal Server has been recognized in the "Best Portal Platform" category in the recently announced SYS-CON SOA World Reader's Choice Awards for 2007. Read the full announcement here.

Overall, Sun has won several top awards, including for the Best Application Server (read more commentary on The Aquarium).

About

atul

Search

Archives
« April 2014
SunMonTueWedThuFriSat
  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
   
       
Today