Grant Ingersoll wrote:
I have an object that I would like to share between two or more RequestHandlers. One request handler will be responsible for the object and the other I would like to handle information requests about what the object is doing. Thus, I need to share the object between the handlers. Short of using a static, does anyone have any recommended way of doing this? In a pure servlet, I could use the ServletContext. Or am I missing something?


RequestHandlers can know about each other by asking SolrCore

    core.getRequestHandler( "myhandler" )

If you are using 1.3-dev, make the RequestHandler implement SolrCoreAware and then inform( SolrCore ) will be called *after* everything is initialized.

is that what you need?

ryan

Reply via email to