WSRP Quick Reference
By ajitsabnis on Sep 13, 2006
Web Services for Remote Portlets (WSRP), Web Services for Interactive Applications (WSIA)Web service interface(s) for accessing and interacting with presentation-oriented web services.
Producers = Web services conforming to WSRP spec
Consumers = Applications consuming Producers in manner conforming to WSRP spec
Self description, Markup
Registration, Portlet management
portletHandle = Identifies a particular Portlet, passed between Consumer and Producer
"Producer Offered Portlets" = Fixed set of Portlets available to Consumers
Consumer = AggEngine/Portal
Intermediary system (proxy?) that communicates with Producer on behalf of End-User
Lifecycle = How items become available, are interacted with, and are destroyed
- Persistent lifecycle = Create item explicitly, use it, and destroy it explicitly
- Transient lifecycle = Create item implicitly as side effect of some operation, gets used, and destroyed implicitly
- Registration scope = Starts when Consumer registers with a Producer and ends when registrationHandle is released, i.e. Consumer-Producer relationship ends
- Portlet scope = Starts when a Portlet becomes Producer Offered Portlet and ends when the Portlet is removed from Producer Offered Portlets set. Starts when a (Producer Offered) Portlet is cloned to become Consumer Offered Portlet.
- Session scope = Starts when a Portlet needs to store transient state on Producer and ends when the session holding such state is released
- Navigational state = State that allows current page fragment to be correctly generated multiple times
- Transient state
- Interaction state = State supplied to the processing of an interaction with Portlet's markup, e.g. input parameters to such processing
- Session state = sessionID
- Persistent state = State that is persisted until Consumer or
Producer discards it
- Consumer registration = registrationHandle
- Portlet = portletHandle
Interface SummaryInterface between Consumer and Producer; Consumer invoking operations on Producer. [Pull, no Push]
Good way to specify high level interfaces. Return values for such interface seem odd at such high level, e.g. returning PortletContext after setPortletProperties.
Service DescriptionTo get Producer's meta-data...
ServiceDescription = getServiceDescription(RegistrationContext, desiredLocales);
MarkupTo get markup...
MarkupResponse = getMarkup(RegistrationContext, PortletContext, RuntimeContext, UserContext, MarkupParams);
To process user interactions with the Portlet markup...
BlockingInteractionResponse = performBlockingInteraction(RegistrationContext, PortletContext, RuntimeContext, UserContext, MarkupParams, InteractionParams);
To assist Producer in pre-initializing HTTP cookies...for managing End-User session...
ReturnAny = initCookie(RegistrationContext);
To let Producer know that End-User session(s) are done with...
ReturnAny = releaseSessions(RegistrationContext, sessionIDs);
RegistrationTo establish a relationship with Producer...
RegistrationContext = register(RegistrationData);
To update such relationship...
RegistrationState = modifyRegistration(RegistrationContext, RegistrationData);
To break up with the Producer...
ReturnAny = deregister(RegistrationContext);
Potlet ManagementTo get Portlet meta-data...
PortletDescriptionResponse = getPortletDescription(RegistrationContext, PortletContext, UserContext, desiredLocales);
To ask Producer to clone Portlet to customize it...to create Consumer Configured Portlet...
PortletContext = clonePortlet(RegistrationContext, PortletContext, UserContext);
To destroy Consumer Configured Portlet...
DestroyPortletsResponse = destroyPortlets(RegistrationContext, portletHandles);
To customize Consumer Configured Portlet...
PortletContext = setPortletProperties(RegistrationContext, PortletContext, UserContext, PropertyList);
To get Portlet properties...
PropertyList = getPortletProperties(RegistrationContext, PortletContext, UserContext, names);
Just to get Portlet property description?
PortletPropertiesDescriptionResponse = getPortletPropertyDecription(RegistrationContext, PortletContext, UserContext, desiredLocales);