You can point that to your index (note that there's some locking, so do this when you site is not publishin/indexing) - and you can actually see what fields are in the index - a good starting point for debugging.
Also - in case it helps you, some simple search code that I (am pretty sure) was working at some point.
Hi - I think the first thing to try and do is use the Luke examiner I mentioned (http://www.getopt.org/luke/) - download and run the main .jar file, then point that to the folder you have your index in.
That will tell you if you have data in your index (and you will be able to see the field names and values), then you will know if you're problem is 1) configuring the indexing, or 2) the code interrogating this (above).
Likely it's the first - there's indexing events (ongatheringnodedata) you can hook into and debug - hope that helps...
Thanks, I downloaded luke and pointed it to my index, seems like my index is empty, since it says it has 0 fields, 0 documents etc.
My question is... how do I fill the index with data ? in what event does the index get filled ? I tried publishing the whole website, but the index remains empty...
I downloaded the examine-dashboard, thanks for that, and the problem is that there is a file at the queue, I tried deleting the queue and rebuilding the index but there's always a file at the queue:
"1 file in queue -> Last update 11/21/2011 1:41:09 PM - 634574796690742435-DESKTOP2.del ..."
The InternalIndexer and InternalMemberIndexer build just fine and at the end of the rebuilding process, the queus are cleared, what can be the cause of the hanging of the queue ? somebody ?
public UmbracoExamineEvents() { foreach (BaseIndexProvider indexer in ExamineManager.Instance.IndexProviderCollection) { indexer.IndexingError += new EventHandler<IndexingErrorEventArgs>(UmbracoExamine_IndexingError); indexer.NodesIndexed += new EventHandler<IndexedNodesEventArgs>(indexer_NodesIndexed); indexer.NodesIndexing += new EventHandler<IndexingNodesEventArgs>(indexer_NodesIndexing); }
var somethingIndexer = ExamineManager.Instance.IndexProviderCollection[SOMETHING_INDEXER_NAME]; if (somethingIndexer != null) somethingIndexer.GatheringNodeData += SomethingIndexer_OnGatheringNodeData;
var clIndexer = ExamineManager.Instance.IndexProviderCollection[SOMETING_ELSE_INDEXER_NAME]; if (clIndexer != null) { clIndexer.NodeIndexed += clIndexer_NodeIndexed; clIndexer.IndexingError += clIndexer_IndexingError; }
examine search
Hi.
I'm trying to perform a search using the following code, but search results are always empty.
I have searched for a simple "a" in the search term and got 0 matches.
to simplify the example I have a simple filter:
(Sorry for the extra post, but it won't let me edit)
How do I know if the index has been created properly ?
Hi - I found this quite useful when working with Examine http://www.getopt.org/luke/
You can point that to your index (note that there's some locking, so do this when you site is not publishin/indexing) - and you can actually see what fields are in the index - a good starting point for debugging.
Also - in case it helps you, some simple search code that I (am pretty sure) was working at some point.
Hi thomas,
I used your code, but when I debug and put a watch on filter I get null null null null for the fields ?
What does it mean ? Do I have a problem with the indexing ?
Hi - I think the first thing to try and do is use the Luke examiner I mentioned (http://www.getopt.org/luke/) - download and run the main .jar file, then point that to the folder you have your index in.
That will tell you if you have data in your index (and you will be able to see the field names and values), then you will know if you're problem is 1) configuring the indexing, or 2) the code interrogating this (above).
Likely it's the first - there's indexing events (ongatheringnodedata) you can hook into and debug - hope that helps...
Thanks, I downloaded luke and pointed it to my index, seems like my index is empty, since it says it has 0 fields, 0 documents etc.
My question is... how do I fill the index with data ? in what event does the index get filled ? I tried publishing the whole website, but the index remains empty...
olst,
download the excellent http://our.umbraco.org/projects/developer-tools/examine-dashboard that will allow you to rebuild indexes.
Regards
Ismal
Hi Ismail,
I downloaded the examine-dashboard, thanks for that, and the problem is that there is a file at the queue, I tried deleting the queue and rebuilding the index but there's always a file at the queue:
"1 file in queue -> Last update 11/21/2011 1:41:09 PM - 634574796690742435-DESKTOP2.del ..."
The InternalIndexer and InternalMemberIndexer build just fine and at the end of the rebuilding process, the queus are cleared, what can be the cause of the hanging of the queue ? somebody ?
Hi - that's a "delete request" for the Lucene indexer - if you open it in notepad you can see what it's asking Lucene to delete.
If this is failing then perhaps you have write permission issue, check the IIS app pool identity has write perms on your folder.
More generally - try and hook into the Examine events and see if you can debug the issue - some code for you:
is working on a reply...