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

tool to auto generate stub analysis factories


    • Type: Improvement
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 1.3
    • Component/s: None
    • Labels:


      a pet project i've bene working on in some spare time has been looking at source code and byte code analysis toolkits with the goal of being able to write a tool that could be pointed at a jar, and it would generate stub Factories for any TokenFilter or Tokenizer classes it found not already in Solr.

      in the end, it looks like a combination of reflection and some simple pattern matching is actually the best way to go (byte code loses info about param names, and reflection saves a lot of the hassle involved in pure source code analysis)

      i've got a proof of concept ready that i'll attach shortly. I hope to have some time next week to resubmit this as a patch that integrates it with the solr build.xml in such a way that anytime we add/update a lucene jar, we can run "ant stub-factories" and have 99% of the work done for us.


        1. SOLR-396.patch
          40 kB
          Hoss Man
        2. factory-stub.tgz
          4 kB
          Hoss Man

          Issue Links



              • Assignee:
                hossman Hoss Man
                hossman Hoss Man
              • Votes:
                0 Vote for this issue
                0 Start watching this issue


                • Created: