Nesting feeds in one another gives you the possibility
of enriching the hits of a query with other sources to bring related
content to the user. This can be achieved because nested feeds can use
parent metas.
In the following use case, our application starts by retrieving information
about TV series using a CloudView Search feed. It then tries to enrich each hit with images
retrieved by a Google Search feed using the TV series title. We assume that the data source
(http://www.allocine.fr/series/) is crawled by an HTTP connector called series,
properly configured in the Administration Console.
Before you begin: Using more than one feed per page is only possible with Mashup Builder Premium.
In Mashup Builder, open one of your application
pages, for example search, and select the Feeds
view.
Drag and drop a CloudView Search feed and from
the Feed ID field, call it tvseries.
Set the feed properties as follows:
For Query, enter source:series ${page.params["q"]} where
source:series specifies the name of the HTTP connector
that crawls TV series in the Administration Console.
For Hits per page, enter the number of
hits to display on the search results page, for example 4
Drag and drop an Google Search feed within the
CloudView Search feed, and call it pictures.
Set the feed properties as follows:
For Query, enter ${entry.metas["title"]}
(the title meta for each result of the tvseriesCloudView Search feed).
For Type, select images.
Select the Design view, and add the parent feed
(tvseries) to a widget, for example Result List.
Expand for For each hit, and drag and drop another
widget within the parent widget.
By default the nested feed (pictures) is selected
in the second widget.
Select the Preview to check your configuration
changes.
Click Apply.
The Mashup UI
displays results coming from the 2 data sources. The data
retrieved by the HTTP connector is enriched by pictures retrieved by
Google. Example of hit enrichment in Mashup UI