Question

Given that Lucene is a robust document based search engine could it be used as an Object Database for simple applications (E.G., CMS style applications) and if so what do you see the benefits and limitations?

I understand the role of the RDBMS (and use them on a daily basis) but watned to explore other technologies/ideas.

For example say my domain entities are like:

[Serializable]
public class Employee
{
    public string FirstName {get;set;}
    public string Surname {get;set;}
}

Could I use reflection and store the property values of the Employee object as fields in a Lucene document, plus store a binary serialized version of the Employee object into another field in the same Lucene document?

Was it helpful?

Solution

No. Trying to use Lucene as an effective OODB (Object Oriented Database) is going to be like trying to fit a square peg into a round hole. They're really two completely different beasts.

Lucene is good at building a text index of a set of documents...not storing objects (in a programming sense). Maybe you mis-understand what an Object Oriented Database is. You can check out the definition at Wikipedia:

Object Databases

Object Oriented Databases have their place. If you truly have an application that would benefit from an OODB, I would suggest checking out something like InterSystems Caché

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top