One of the challenges with searching in large organizations is that many times there are multiple SharePoint farms in distributed geographic locations. In previous versions of SharePoint, farm administrators had to configure cross-farm crawls, which were both time-consuming and resource-intensive on the servers. SharePoint 2010 incorporates a feature called Federated Search, which allows a search page to query additional data sources beyond the local SharePoint Search Service. This feature makes use of the open standard OpenSearch 1.1 to query any compliant search server and retrieve results for the same keyword or phrase that has been entered on the search page. This not only eliminates the need for cross-farm crawling but also minimizes the amount of traffic across the WAN because only the query is being sent and a limited number of result links are returned.
To view the existing federated locations installed with SharePoint, from within the Search Service Administration site, under Queries And Results, click the Federated Locations link. The Manage Federated Locations page shown in Figure 9.15 appears.
There are two methods for creating federated locations:
Creating a Federated Location
To create a new federated location, follow these steps:
1. From the Manage Federated Locations page, click the New Location link. This will open the Add Federated Location page shown partially in Figure 9.16.
2. Enter the required information as follows:
3. In the Trigger section, shown in Figure 9.17, determine how this location will be executed on the search page.
The options are:
4. Choose the Location Type setting for the search:
5. If you chose the OpenSearch option for the Location Type setting, configure the query template for the federated location. The query template is equivalent to the URL template in OpenSearch. It references the location’s URL and includes the parameter placeholder for the query terms that will be passed to the location in the query. The template will contain a case-sensitive parameter, {searchTerms}, which will hold the search terms entered by the user. The template can also include other parameters used to filter the query using managed properties. For example, the following is the query template for a Bing search:
http://api.bing.com/rss.aspx?source=web& query={searchTerms}&web.count={count}& web.offset={startIndex}&market={language}& amp;FORM=MO0000&version=2.0" indexOffset="0"
6. In the “More Results” Link Template box, enter a link to the full search results page on the federated location that can be queried directly, along with the replacement parameters. The following example will open the Bing search results page and pass the keyword parameters to it:
http://www.bing.com/search?q={searchTerms}&FORM=MO0001
7. In the Display Information section, shown partially in Figure 9.18, customize how the federated search results will appear.
There are three subsections, each for its associated web page:
Each section has three boxes for formatting the appearance:
8. In the Restrict Usage section, shown in Figure 9.19, select whether you want to control which sites can use this location. The No Restriction option allows any site to use the location. The Use Restriction option will limit the sites to the list specified in the Allowed Sites field. Separate the URLs entered with a semicolon.
9. If you selected either the FAST Index or OpenSearch options, then select an authentication method in the Specify Credentials section:
10. Click OK.
Importing a Federated Location
SharePoint supports importing a predefined search connector file that contains most or all of the appropriate location settings already configured. These files either have the extension .fld (Federated Location Definition file) or .osdx (Windows Search Connector), and you can download samples of both from Microsoft at
http://technet.microsoft.com/en-us/enterprisesearch/ff727944.aspx
To use a location file, open the Manage Federated Locations page and click the Import Location link. On the Import Federated Location page, browse to the file and click OK. You can then edit the definition to customize the settings.
Editing, Copying, Deleting, or Exporting a Federated Location
From the Manage Federated Locations page, click the context menu for any of the existing locations. From here you can edit or delete a location. You can also create a new location by copying an existing one. Doing so duplicates all the settings except the name, which must be unique. The last option is to export the location as an .osdx file for use on another server.
Configuring a Federated Search Web Part
There are three web parts shipped with SharePoint 2010 that support consuming federated locations and displaying the results:
Core Results Web Part This web part is not commonly used to display federated results, but it fully supports locations. The web part Location Properties pane, shown in Figure 9.20, is normally set to the Local Search Results location but can be configured for any federated location. In Figure 9.20 the Bing Federated Search location, which was previously configured, has been selected.
Federated Results Web Part This web part is similar to the Core Results web part but is specifically designed to support passing a search query to a remote location and displaying the results in a sidebar format on the page. In the web part Properties pane, select the Location property in the same way you did for the Core Results web part. Under Display Properties you can specify the number of results to be displayed on the page (the default is 3). The setting Retrieve Results Asynchronously allows the web part to load the search results after the main page has been loaded. This option is checked by default. A Federated Results web part is automatically added to the standard search results page as the People Matches web part.
Top Federated Results Web Part This web part is almost identical to the Federated Results web part except that it can be configured with multiple federated locations. It will query all of the locations but only loads the first set of results returned.
3.147.79.84