• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Lucene 1.9.1 indexing keywords

 
(instanceof Sidekick)
Posts: 8791
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I'm experimenting with upgrading to Lucene 1.9.1 from 1.3 something. Almost every method I used before is now deprecated but the JavaDoc gave solid hints on what to use instead. Now that it's running I'm having trouble searching on keywords. A search like "title:home" used to work fine to find the Home page. Now I get flakey results ... sometimes it works, sometimes not, and now I think not at all.

Here is some relevant code. See anything not right with this?
 
Rancher
Posts: 43081
77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have recently moved from 1.4.3 to 1.9.1 (incidentally, also for a Wiki software), and haven't noticed any differences. I'll give it a more thorough workout over the weekend (and rewrite the code to get rid of obsolescence warnings if there are any), and will get back here with the results.

Updated after getting rid of obsolete methods: Things seem to work fine, but the suggested replacements for obsolete methods are questionable in places. Particularly the suggested values for the "store" and "index" parameters of the new Field constructors are not generally applicable, and should be checked one by one to make sure you're using the correct ones for your purposes.
[ March 12, 2006: Message edited by: Ulf Dittmer ]
 
Stan James
(instanceof Sidekick)
Posts: 8791
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks for the update!

Here's what I figured out. The "title:Home" search works only if the page content contains the word "home". When that's true, it returns only the Home page ... the only match on the title.

A quick workaround for me is to add the page title to the content, but this doesn't seem right. Maybe my search is done wrong?

Changing the CONTENT_FIELD parameter to "title" doesn't seem to help.
[ March 13, 2006: Message edited by: Stan James ]
reply
    Bookmark Topic Watch Topic
  • New Topic