+

Search Tips   |   Advanced Search

Lookup facility in the portal


For both convenience and alignment to other portal REST services, the portal remote REST service for PUMA offers a lookup facility. This is done by plugging a provider into a reusable lookup facility in the portal. This functionality allows us to retrieve particular URLs of the service by specifying an absolute URI as a parameter to the so-called lookup servlet addressed by /wps/poc.

The absolute URIs for the remote REST service for PUMA can be constructed from the service URL paths or be taken from the atom:id elements of the ATOM feeds or entries. The URIs are completely UTF-8 encoded. When constructing a URI manually, you take the URI path after the element /um/ without a leading slash, add um: as URI prefix, and encode the whole expression using UTF-8.

For example, the URL /um/secure/users/profiles?searchAttributes=uid%3Dwps* has the URI um:secure/users/profiles%3FsearchAttributes%3Duid%3Dwps*. We can then call the URL /wps/poc?uri=um:secure/users/profiles%3FsearchAttributes%3Duid%3Dwps* and get redirected to the corresponding REST service URL. Or, when we use the verb=lookup parameter, which is mandatary for operations other than GET, get an ATOM feed with the service description such as the following:

<?xml version="1.0" encoding="UTF-8"?>
<atom:entry xmlns:atom="http://www.w3.org/2005/Atom" xmlns:xhtml="http://www.w3.org/1999/xhtml">
    <atom:author>
        <atom:name>IBM WebSphere Portal</atom:name>
    </atom:author>
    <atom:id>um:secure/users/profiles?searchAttributes=uid=wps*</atom:id>
    <atom:link href="http://setgetweb.com/p/portal80//wps/um/secure/users/profiles?searchAttributes=uid=wps*"/>
    <atom:title>Remote PUMA REST service URI information</atom:title>
    <atom:updated>2006-12-19T19:21:37.562Z</atom:updated>
</atom:entry>
If you need the service description of several REST Service URLs, we can set the uri parameter multiple times using different URIs, and the lookup servlet will aggregate the descriptions into one ATOM feed.


Parent: How the portal implements the remote PUMA REST service
Related:
URL path segment for virtual portals
Identifiers used in the Portal Implementation
Access Control Checks
Use ATOM/APP as input and output format
Switch for tunneling of HTTP methods
HTTP caching
Context root and authentication mechanism