[opencms-dev] Lucene search module.
M Butcher
mbutcher at grcomputing.net
Wed Aug 20 20:38:01 CEST 2003
There are ways of doing that with Lucene, and I am currently trying to
figure out the best way for a project of mine (which is similar to
yours).
The two that seem the best are:
1) Creating separate indices -- this means that each project's data is
stored in a separate set of files. This would be a fairly large
modification to the code, and would be somewhat complex to configure,
but it would accomplish the most thorough separation.
2) Use keywords or other built-in Lucene constructs to constrain
searches. Lucene supports make a particular match a requirement -- that
is, all searches must have keywordA match keywardA_value, and this can
be coded directly into the JSP. This is the easiest way to implement a
subsite search. As far as the existing code goes, though, I don't have a
way to pass that keyword information into the indexer. There should be
some parameters like this:
<keyword>
<name>Subsite</name>
<value>myNewSite</value>
</keyword>
The above should be added on a directory-by-directory basis.
Anyway... those ideas are for the future. For now, you'd probably have
to either write a new implementation of I_DocumentHandler or extend the
appropriate I_DocumentHandler implementations.
Matt
On Wed, 2003-08-20 at 11:54, Marcus Redeker wrote:
> Matt,
>
> great work with the search module!!! I was about to make something
> myself and than I found yours in the Sandbox!! It works like a charme. I
> have one question though: Is it possible to index different directories
> and have the search only search within the index for that one directory?
> We are having multiple projects within our virtual filesystem like this:
>
> /project1/....
> /project2/....
>
> And I don't want the search page in project1 find pages from project2.
>
>
> Thanks again,
>
> --Marcus
>
>
> _______________________________________________
> This mail is send to you from the opencms-dev mailing list
> To change your list options, or to unsubscribe from the list, please visit
> http://mail.opencms.org/mailman/listinfo/opencms-dev
--
M Butcher <mbutcher at grcomputing.net>
More information about the opencms-dev
mailing list