Ayschronous Search

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Ayschronous Search

aminm
Hi

I am currently working on building a proof of concept search solution for my company using Lucene and Hibernate Search.  I have built individual components which work fine.  I am now looking at creating a single api that would allow a user to get search results back from different sources (domain + data).  What I would like to achieve is something like a search manager fires search requests to different search components asynchronously and when one set of results have been processed return that result to the user while processing the rest.  Once the result of the search has been processed notify teh client that there are more search results available. 

I came across your article 'http://java.dzone.com/articles/writing-rest-application-comet' and I was wondering if I could get peoples opinion on whether the use of Comet/Atmosphere a good approach?

Cheers
Amin

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Ayschronous Search

Jeanfrancois Arcand
Salut,

Amin Mohammed-Coleman wrote:

> Hi
>
> I am currently working on building a proof of concept search solution
> for my company using Lucene and Hibernate Search.  I have built
> individual components which work fine.  I am now looking at creating a
> single api that would allow a user to get search results back from
> different sources (domain + data).  What I would like to achieve is
> something like a search manager fires search requests to different
> search components asynchronously and when one set of results have been
> processed return that result to the user while processing the rest.  
> Once the result of the search has been processed notify teh client that
> there are more search results available.
>
> I came across your article
> 'http://java.dzone.com/articles/writing-rest-application-comet' and I
> was wondering if I could get peoples opinion on whether the use of
> Comet/Atmosphere a good approach?

I'm biased since I'm the creator of Atmosphere, but what your are
describing above can easily be implemented using a suspend/resume
architecture. The idea is to suspend the request, delegate the search to
the search manager, and resume once the result are ready. All
application server those days have their own Suspend/Resume API, but
Atmosphere is a layer on top so you can write you application and deploy
in any java web server supporting the Servlet 2.5 and up specification.

You can either use the Atmosphere-core module (which supports REST via
Jersey) or the lower lever component called atmosphere-cpr (cpr=Comet
portable Runtime). You can see a blog here:

http://weblogs.java.net/blog/jfarcand/archive/2009/03/getting_started_1.html

Hope that help, and don't hesitate to ask more questions :-)

-- Jeanfrancois



>
> Cheers
> Amin
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Loading...