Uploaded image for project: 'Solr'
  1. Solr
  2. SOLR-182

register SolrRequestHandlers at runtime / lazy loading

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 1.2
    • None
    • None

    Description

      It would be useful to be able to register handlers after SolrCore has been initialized initialized. It is also useful to be able to ask what handlers are registered and to where. This patch adds the following functions to SolrCore:

      SolrRequestHandler registerRequestHandler(String handlerName, SolrRequestHandler handler);
      Collection<SolrRequestHandler> getRequestHandlers(Class<? extends SolrRequestHandler> clazz);

      It also guarantees that request handlers will be initialized with an argument saying what path it is registered to. RequestHandlerBase gets a bean for the registered path.

      While discussing this, Yonik suggested making it possible to defer initialization of some handlers that will be infrequently used. I added the 'LazyRequestHandlerWrapper' (if taking this out makes the patch any easier to commit - it can get its own issue)

      check:
      http://www.nabble.com/Dynamic-RequestHandler-loading-tf3351707.html

      Attachments

        1. SOLR-182-RuntimeRequestHandlers.patch
          23 kB
          Ryan McKinley
        2. SOLR-182-RuntimeRequestHandlers.patch
          23 kB
          Ryan McKinley
        3. SOLR-182-RuntimeRequestHandlers.patch
          23 kB
          Ryan McKinley
        4. SOLR-182-RuntimeRequestHandlers.patch
          22 kB
          Ryan McKinley
        5. SOLR-182-RuntimeRequestHandlers.patch
          18 kB
          Ryan McKinley
        6. SOLR-182-RuntimeRequestHandlers.patch
          22 kB
          Ryan McKinley
        7. SOLR-182-RuntimeRequestHandlers.patch
          59 kB
          Ryan McKinley

        Issue Links

          Activity

            People

              Unassigned Unassigned
              ryantxu Ryan McKinley
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: