Programming Tutorials Browser Tutorials Articles Struts Tutorials Hibernate Tutorials

  Tutorial: Using Lucene With OJB

Brian McCallister looks at the Lucene search engine and shows us how to index and retrieve objects from a sample Student application.

Tutorial Details:

The Student objects are persisted using ObjectRelationalBridge (OJB); Brian shows us how to query against
the Student index, pull out all the pk's for the hits, then select for the domain objects using those pks.

The primary use case for this application is for a student coop employee to be finding a student in the system, then finding gear and checking the gear out for the student. Finding the student is key, and that is best served by... searching! So we have a database record for each student, and want to have a convenient search facility, which can search based on name, student id (idNumber), phone number, even address. Lucene makes this is a snap. To do it, we just store the id (internal/pk id) in an unindexed field when we add a student in the StudentIndexer:


 

Read Tutorial at: Click here to view the tutorial

Rate Tutorial:
Using Lucene With OJB

View Tutorial:
Using Lucene With OJB

Related Tutorials:

The Lucene search engine: Powerful, flexible, and free - JavaWorld September 2000
The Lucene search engine: Powerful, flexible, and free - JavaWorld September 2000
 
Creating EL-Aware Taglibs Using XDoclet
Creating EL-Aware Taglibs Using XDoclet When the JSP Tag Extensions (also known as taglibs) first came out, the only option to pass dynamic values as tag attributes was using Request Time (RT) expressions. With the advent of JSTL 1.0, another option ha
 
Developing Swing Components Using Simulators
Developing Swing Components Using Simulators In this article, you'll learn about a technique for developing encapsulated components. You'll also learn about how to test graphical parts of your application that JUnit can't, such as layouts and other visua
 
Develop Your Own Plugins for Eclipse, Part 1
This article series is intended provide you the basic information necessary to quickly code your first plugin. The resources section will point to all of the necessary introductory materials.
 
Euler proof mechanism
Euler is an inference engine supporting logic based proofs of test cases (*).
 
Using the ASM Toolkit for Bytecode Manipulation
Using the ASM Toolkit for Bytecode Manipulation Sometimes Java developers need to generate or change Java bytecode in the runtime. Is can be necessary for AOP or debugging, or even for performance optimization. There are several frameworks available that
 
Using Timers in J2EE Applications
Using Timers in J2EE Applications Job scheduling is nothing new--most enterprise applications require the scheduling of tasks and activities. For example, your application may need a timer service to run a business process once a day, or to clean up a te
 
JTwain
JTwain will implement a Java interface to the the Win32 C DLL TWAIN acquire methods.
 
yawiki (Yet Another Wiki)
yawiki (Yet Another Wiki) A wiki system is a perfect place for working together and sharing informations. The syntax for the wiki system is really simple to learn. Getting started with a wiki system is easy.
 
Lucene in Action
Lucene in Action Lucene is a gem in the open-source world--a highly scalable, fast search engine. It delivers performance and is disarmingly easy to use. Lucene in Action is the authoritative guide to Lucene. It describes how to index your data, includin
 
Accessing Databases Using Java and JDBC
This article will show how a Java Application, Applet or Servlet can access data stored in relational databases using the JDBC API.
 
Jeff Schmitt's JDBC Page
This tutorial assumes you are using the MySQL database and the GWE JDBC drivers. The host computer is triton.towson.edu.
 
Using Lucene With OJB
Brian McCallister looks at the Lucene search engine and shows us how to index and retrieve objects from a sample Student application.
 
Running Lucene Search on WebLogic Portal 8.1
Lucene comes with two main services available: indexing and searching. The indexing tasks are done independently from the search tasks. Both the index and search services are available so that developers can extend them to meet their needs.
 
Unweaving a Tangled Web With HTMLParser and Lucene
In this article I'll show you the basic technique in building a search engine using two powerful Open Source products: HTMLParser and Lucene.
 
Adding search to your applications
The Lucene search engine is an open source, Jakarta project used to build and search indexes. Lucene can index any text-based information you like and then find it later based on various search criteria.
 
Tech Tip: Using the Varargs Language Feature
Have you ever needed to pass in many instances of the same object type to a method, but you don't know at compile time how many instances there will be? Find out how the new varargs language feature makes it easy to handle situations like this.
 
What is Persistence Framework?
What is Persistence Framework? What is Persistence Framework? A persistence framework moves the program data in its most natural form (in memory objects) to and from a permanent data store the database. The persistence framework manages the
 
Welcome to the MySQL Tutorials
Welcome to the MySQL Tutorials Welcome to the MySQL Tutorials Using MYSQL Database This lesson is intended to provide hands an experience with MYSQL database Backing Up and Restoring A MySQL Database In this lession you will learn how to take
 
Urchin RSS Aggregator
Urchin is a Web based, customisable, RSS aggregator and filter. It\'s primary purpose is to allow the generation of new RSS feeds by running queries against the collection of items in the Urchin database.
 
Site navigation
 

 

Send your comments, Suggestions or Queries regarding this site at roseindia_net@yahoo.com.

Copyright © 2006. All rights reserved.