Problem

With evolution of search, different kinds of requirements arise for searching content. One of the requirements we came across was that they wanted to search for content from external locations (i.e. like Google, YouTube and other public facing internet applications).


Solution

SharePoint 2010 has a web part called "Federated Results". This searches content from the configured federated locations (like Google) that search content on provided parameters and generates output.

In this article, we will be concentrating on how to search content from such external applications. For this article, we will take "YouTube" as an external location. To define a federated (external) location, go to Central Administration > Application Management > Service Applications > Manage Service Applications > Search Service Applications. Click on "Federated Locations" under "Queries and Results" category.



Add a new location. We will first fill the general information: Location name (Youtube), display name (Youtube) and description (any suitable description) which makes a location unique.



Moving ahead to the Location Information category, we need to select the protocol which we will search content (i.e either Search index on the server, Fast index or opentext 1.0/1.1). For our requirement to define the YouTube location, we will select the Opentext protocol.

We also need to provide one mandatory detail which is the Query Template - which mentions from which location we will search and what will be the search parameter.

For our requirement we need to mention, "http://www.youtube.com/rss/tag/{searchTerms}.rss" where "searchTerms" will be the content searched in search box. Optionally, we can also provide a link for "More Results" that will appear at the bottom of search (as shown in the image below).

Leave the rest of the options to defaults.

Click on OK and add location.



Perform a full incremental crawl after the location is created.

Now go to the web application > search center results page and add a web part named "Federated Results" from "Search" Categories.



Edit the Web Part properties and browse to the Location section under Location Properties. If everything above is performed accurately, an option named "Youtube" will appear. Select it and apply changes.



Now we will search some content like "Microsoft" and we could see that with the search core results, a column of search results appears on right side of the screen which provides search results related to "microsoft" from youtube.



By implementing a process this way, it can reduce overburden of configuration and management of searching from federated locations.