lucene.net

What is the latest version of Lucene.net?

≡放荡痞女 提交于 2019-12-06 14:29:12
From where do I download the latest version of Lucene.net dll? I am right now using 2.0.0.4 version but its MultiFieldQueryParser's constructor does not accept boost values. Here! Looks like v2.0-004 is the latest version though. 2.0.0.4 is the latest package that they have available. However, if you don't mind building from the source, 2.3.1 is the latest stable that they have in the trunk. You can just pull down something like TortoiseSVN and pull it from the repository . I built it with no issues at all. 来源: https://stackoverflow.com/questions/554608/what-is-the-latest-version-of-lucene-net

How to maintain Lucene index availability during rebuild?

冷暖自知 提交于 2019-12-06 14:21:38
When rebuilding indexes on a content delivery server, any components that search that index fail (blow up). How can I rebuild my index without causing the search components to be unavailable? Furthermore, is there a standard way to handle this? The code I'm using to perform the reindex on regular intervals: Sitecore.Data.Database db = Sitecore.Configuration.Factory.GetDatabase(DBName); Index index = db.Indexes[IndexName]; index.GetSearcher(db).Close(); index.Rebuild(db); To give a little context: Sitecore version - 6.4.1 (rev. 110324) It is necessary to rebuild the index because it contains

Is it possible to add custom metadata to a Lucene field?

喜你入骨 提交于 2019-12-06 11:56:45
问题 I've come to the point where I need to store some additional data about where a particular field comes from in my Lucene.Net index. Specifically, I want to attach a guid to certain fields of a document when the field is added to the document, and retrieve it again when I get the document from a search result. Is this possible? Edit: Okay, let me clarify a bit by giving an example. Let's say I have an object that I want to allow the user to tag with custom tags like "personal", "favorite",

How to perform a wildcard search in Lucene

本小妞迷上赌 提交于 2019-12-06 11:54:29
问题 I know that Lucene has extensive support for wildcard searches and I know you can search for things like: Stackover* (which will return Stackoverflow ) That said, my users aren't interested in learning a query syntax. Can Lucene perform this type of wildcard search using an out-of-box Analyzer? Or should I append "*" to every search query? 回答1: Doing this with string manipulations is tricky to get right, especially since the QueryParser supports boosting, phrases, etc. You could use a

Lucene.NET MoreLikeThis Example

纵然是瞬间 提交于 2019-12-06 11:41:58
问题 Could anyone give an example of how to use the MoreLikeThis feature in Lucene.NET. I have searched online and cannot find a single example. 回答1: (Resurrecting an old question!) As an example for Lucene.Net 2.9.4g: var moreLikeThis = new Lucene.Net.Search.Similar.MoreLikeThis(indexReader); moreLikeThis.SetAnalyzer(analyzer); moreLikeThis.SetFieldNames(fieldNames); moreLikeThis.SetStopWords(stopWords); moreLikeThis.SetMinWordLen(2); var query = moreLikeThis.Like(new System.IO.StringReader

Improving performance of Location based search using Lucene

一个人想着一个人 提交于 2019-12-06 11:40:02
I'm using Lucene for a job search portal using .net. Am facing some performance related issues in the following use case. Use case is: When doing job search, user can select job location(for exameple:Atlanta,GA) and select radial distance (say 50 miles).The time required to return job search results from Lucene is pretty high. FYI,we are maintaining a sql server 2005 database where we store US and Canada based city,state,longitude and latitude.(contains a total of about 1 million records). Is there anyway I can improve the performace of this location based job search? Basically, you have two

Lucene .NET not returning search results

雨燕双飞 提交于 2019-12-06 11:37:32
For some reason lucene is not returning any results when it should be. Here is the 'search' code Dim util As New IndexerUtil() Dim dir As Lucene.Net.Store.Directory = FSDirectory.Open(New DirectoryInfo(util.getIndexDir())) Dim indexSearcher As New IndexSearcher(dir, False) Dim indexWriter As New IndexWriter(dir, New SimpleAnalyzer(), False, indexWriter.MaxFieldLength.UNLIMITED) Dim term As New Term("id", "346") Dim query As New TermQuery(term) Dim topDocs As TopDocs = indexSearcher.Search(query, 100) There are no scoreDocs (results) in topDocs. I know for a fact that there is a document in the

How To implement LuceneNet using Amazon S3

谁说胖子不能爱 提交于 2019-12-06 11:28:05
I'm trying to implement Lucene in my app using Amazon S3 to storage the indexes that I generate, but I can find any code examples or a clear article. So anyone that have some kind of experience with this please give a guide or something that can help me start Marko Bonaci There's a similar question here . Here 's an interesting article of how the biggest Solr service provider Lucid Imagination proposes to deploy their Solr implementation on EC2. And here 's their Search-as-a-Service solution. If you're not bound to S3, you can use dedicated Solr cloud service called WebSolr . Also, if you need

Lucene.NET - do an AND search multiple words on multiple fields

喜夏-厌秋 提交于 2019-12-06 10:39:17
I define a Document object for my product entity which has several fields: Title, Brand, Category, Size, Color, Material. Now I want to support user to do an AND search on multiple fields. Any document that have one, two or more fields contain all the search words will be responded. For example, when user enter "gucci shirt red" I want to return all documents that have fields matched with all 3 tokens "gucci", "shirt" AND "red". So all documents below will be responded: 1.Documents with title contains all the 3 words, for example Title = "Gucci Modern Shirt Red" or "Gucci blue shirt"... 2

Lucene .Net optimization process

爱⌒轻易说出口 提交于 2019-12-06 09:16:50
问题 I am creating an index using Lucene .Net 2.9.2. After a lot of indexing, the index has many segments and deleted documents, so I am calling Optimize(numSegmets) on the IndexWriter. The index's segments count is indeed reduced to the value of numSegmets , but it still has deletions... doesnt a call to Optimize should also remove all deleted documents? My question is very important so I could know if this is how Lucene works or maybe I have some bug... Edit: here is my code snippet: IndexWriter