Patterns in ProcessEvent annotation

In the ProcessEvent annotation entry i built a sample portlet to demonstrate how we can use @ProcessEvent annotation.

When the processEvent() method in GenericPortlet gets invoked, first it checks if there there is exact match of event name and the value of name attribute of @ProcessEvent annotation. If it does not find exact match it tries to find the longest possible match using following rule

"If the local part of the event name has a wildcard at the end (“.”) the GenericPortlet will try to match the received event either to the same wildcard event name or to the longest matching event name for this wildcard. E.g. if an event with the local part of the event name of "a.b.c.d" is being received and there are methods annotated for handling "a.b." and "a.b.c." events in this portlet, the GenericPortlet will dispatch the event to the method annotated with "a.b.c."

Lets say this is how portelt.xml of my target portlet looks like

<?xml version="1.0" encoding="UTF-8"?>
<portlet-app xmlns=""
version="2.0" xmlns:xsi=""
<display-name>Process Event Annotation Portlet</display-name>
<title>Process Event Annotation Portlet</title>
<short-title>Process Event Annotation Portlet</short-title>
<keywords>Process Event Annotation Portlet</keywords>


The ProcessEventAnnotationPortlet can consume event. So these are some of the @ProcessEvent combination that i can use to handle this event

  1. @ProcessEvent(qname="{}"): Fully qualified event name

  2. @ProcessEvent(qname="{}com.webspherenotes."): Fully qualified event name, so this method can handle all the events starting with com.webspherenotes.*, it could be,

  3. @ProcessEvent(name = "com.webspherenotes."): Means it can handle all the events where local name starts with com.webspherenotes.*


srjwebsolutions said...

We are leading responsive website designing and development company in Noida.
We are offering mobile friendly responsive website designing, website development, e-commerce website, seo service and sem services in Noida.

Responsive Website Designing Company in Noida
Website Designing Company in Noida
SEO Services in Noida
SMO Services in Noida

Vikas Chaudhary said...

Battery Mantra is Authorized exide car battery dealer in Noida and Greater Noida. We are providing our service in Indirapuram, Delhi, Ashok Nagar.

Exide Battery Dealer in Noida
Battery Dealer in Noida
Authorized Battery Dealer in Noida
Car Battery Dealer in Noida
Car Battery Dealer
Exide Battery Dealer

EG MEDI said... is online medical store pharmacy in laxmi nagar Delhi. You can Order prescription/OTC medicines online.
Cash on Delivery available. Free Home Delivery

Online Pharmacy in Delhi
Buy Online medicine in Delhi
Online Pharmacy in laxmi nagar
Buy Online medicine in laxmi nagar
Onine Medical Store in Delhi
Online Medical store in laxmi nagar
Online medicine store in delhi
online medicine store in laxmi nagar
Purchase Medicine Online
Online Pharmacy India
Online Medical Store