Chad Scott 110000E1UB Visits (5153)
Installing and configuring type-ahead search is a relatively straightforward process. What may be less clear, however, is validating that it works. That's the situation I found myself in when setting it up for the first time. I like to validate everything I set up, but it wasn't clear to me how to do so for type-ahead search. What gets indexed? When is it indexed? How do I know it's actually working?
First, a bit of background information. Solr is an open source search platform that is used to implement the back end of Connections type-ahead search. It's the thing that gets installed and configured. When users access Connections content, requests are sent to Solr that contain metadata about the accessed content. This metadata includes items like the content's title and URL and the user ID of the person accessing the content. It does not include the content data itself. Solr takes this metadata and--in real time--indexes it as a document. Unlike Connections search, indexing does not occur at regular intervals.
To validate Solr index data, we can use the Solr admin UI to execute searches as Connections data is accessed. To get started, navigate to http
The main pane will allow us to execute arbitrary queries against the Solr data. Our first goal is to verify that we see documents indexed when accessing Connections content, so we'll first add last
With this set, it's time to access content in Connections. In this example, I've just accessed a community named Global Communications with a user named email@example.com. All I need to do on the Solr admin Query page is click the Execute Query button to see the most recently indexed documents. Solr returns a JSON object of 10 documents by default, and it will be the most recent 10 because of the sort field value we set earlier. Here's what I see as the most recent document:
Sure enough, this document describes the Global Communications community, and the user ID is the UUID for firstname.lastname@example.org. As I navigate to more content in Connections, subsequent queries will return additional documents that represent the visited content. Note that content is indexed by user so that the type-ahead can display results pertinent to the user executing the search. If I have another user email@example.com who has not visited the Global Communications community, no Solr document will exist for that community and user pairing.
Now that we've validated that Solr is indexing our Connections activity, we'll want to validate that the type-ahead search results we see match what we see when running queries via the Solr admin UI. Using the same firstname.lastname@example.org user, I'll access the search control in Connections and begin a type-ahead search for Global Communications.
To run an equivalent search in Solr, we'll return to the Query page. This time we'll add a query string approximating the search Connections uses.
Our results precisely match what is returned by the type-ahead search.
At this point I have validated both the index and search phases of type-ahead search and am confident that the feature is working as intended.
Chad Scott 110000E1UB Visits (8414)
A colleague of mine asked for some help benchmarking the time required to build background indexes on an IBM Connections 5.0 CR2 test system with very little data. To test that, I ran the following wsadmin command as described in Sear
However, I ran into the following error:
CLFRW0807W: Problem creating an FSDirectory instance from this class class org.
Caused by: java
Initially I thought this was due to not creating the seedlist, extract, and index directories before running the command, but doing so yielded the same error on a subsequent indexing attempt. The issue turned out to be the case used in the paths provided in the wsadmin command. While Windows is not case-sensitive, the Java methods invoked are, and using the wrong case throws the java
The correct way to run that command on my system is:
If you are lazy like me and tend to ignore case on Windows, get in the habit of making sure to use exact case for any wsadmin command, regardless of platform. Oh, and the time required for all indexes on a nearly empty system? About 40 seconds.
Chad Scott, software engineer on the IBM Connections Support team