Monthly Archives: April 2008

FAST SharePoint Integration: Sample Code to Display All Available FAST Views

 

Here is some code that shows all available views from a FAST server based on the named QRServer (the server process with which we communicate).  I offer this up to give you all a taste of what it’s like to use the provided FAST API.

 

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Com.FastSearch.Esp.Search;
using Com.FastSearch.Esp.Search.Http;
using Com.FastSearch.Esp.Search.Navigation;
using Com.FastSearch.Esp.Search.Query;
using Com.FastSearch.Esp.Search.Result;
using Com.FastSearch.Esp.Search.View;
using System.Collections.Specialized;
using System.Collections;


namespace Conchango
{
    class EnumerateFASTViews
    {
        static void Main(string[] args)
        {

            ISearchFactory searchFactory;

            NameValueCollection nameValueCollection = new NameValueCollection();

            nameValueCollection.Add("fastsearchengine", "Com.FastSearch.Esp.Search.Http.HttpSearchFactory");
            nameValueCollection.Add("Com.FastSearch.Esp.Search.Http.QRServers", "fastdemoback:15100");
            nameValueCollection.Add("Com.FastSearch.Esp.Search.Http.RequestMethod", "GET");

            searchFactory = SearchFactory.NewInstance(nameValueCollection);

            Console.WriteLine("Total Views: [" + searchFactory.GetSearchViewList().Count + "].");

            int i = 0;

            foreach (object o in searchFactory.GetSearchViewList())
            {
                Console.WriteLine("View [" + i++ + "]: [" + o.ToString() + "].");

            }

            Console.ReadLine();

        }
    }
}

 

Note that I consider myself a barely competent C# programmer and I have thin skin, so don’t send any raspberries my way, especially re: the "foreach (object o in …)" construct 🙂

</end>

Technorati Tags: ,

Subscribe to my blog.

FAST and SharePoint Integration First Look

I’ve been lucky to have an opportunity to work on a FAST <–> SharePoint integration project and thought I’d continue to share my limited experience with the community.

Microsoft is in the process of purchasing FAST.  I don’t know anything about the schedule except that it should be finished in the "2nd quarter" which I assume means by 06/30/08.

My project’s design, at a very high level, calls for creating a few web parts that have roughly the same look, feel and functionality as the standard MOSS search box and core results web part, but pulling from FAST.  I’ve made some baby steps in that direction.

FAST is a dedicated search engine.  It’s not based on Microsoft technology, though it’s obvious to me that some of the FAST engineers clearly understand MS tech (or they’ve made use of contractors). 

FAST:

FAST is a big monster server product (and I don’t mean that in a bad sense; MOSS is a big monster product to me as well).  It appears to be based on Java and I noticed some apache stuff and maybe some PHP.  I wouldn’t be surprised if there were other bits of tech mixed in here and there.  It definitely runs on windows server and is working fine in the virtual environment which I’ve been using.

It makes use of a facade web service that crawls SharePoint content for indexing in its special FAST way. 

A SharePoint end user would be pretty much at home with FAST’s user interface.  It has simple/advance search, shows results, is big on relevancy (though I don’t see how it handles social relevancy).  However, it does go further.  Its stemming seems better.  I really can’t articulate it well but I’ll just say "it’s better."  You can take my word for it, or not 🙂  I may elaborate on this point in the future, as I learn more.

MOSS:

FAST provides a .NET-friendly DLL that provides an interface to the FAST engine.  This makes it possible for us to create web parts or application pages or whatever we want to query FAST and present the results.

There seems to be a web service interface as well.

I also have access to a FAST-provided web part that does integrate MOSS and FAST.  I don’t know if this is a POC, something that was whipped up as a demo or what.  It’s definitely a good learning tool, not so sure if it’s production-ready.

That’s it for now.  As I progress through the project, I’ll post more.

</end>

Technorati Tags: , ,

Subscribe to my blog.