Solr
  1. Solr
  2. SOLR-1725

Script based UpdateRequestProcessorFactory

    Details

      Description

      A script based UpdateRequestProcessorFactory (Uses JDK6 script engine support). The main goal of this plugin is to be able to configure/write update processors without the need to write and package Java code.

      The update request processor factory enables writing update processors in scripts located in solr.solr.home directory. The functory accepts one (mandatory) configuration parameter named scripts which accepts a comma-separated list of file names. It will look for these files under the conf directory in solr home. When multiple scripts are defined, their execution order is defined by the lexicographical order of the script file name (so scriptA.js will be executed before scriptB.js).

      The script language is resolved based on the script file extension (that is, a *.js files will be treated as a JavaScript script), therefore an extension is mandatory.

      Each script file is expected to have one or more methods with the same signature as the methods in the UpdateRequestProcessor interface. It is not required to define all methods, only those hat are required by the processing logic.

      The following variables are define as global variables for each script:

      • req - The SolrQueryRequest
      • rsp- The SolrQueryResponse
      • logger - A logger that can be used for logging purposes in the script
      1. SOLR-1725-rev1.patch
        60 kB
        Simon Rosenthal
      2. SOLR-1725.patch
        38 kB
        Uri Boness
      3. SOLR-1725.patch
        34 kB
        Uri Boness
      4. SOLR-1725.patch
        36 kB
        Uri Boness
      5. SOLR-1725.patch
        54 kB
        Uri Boness
      6. SOLR-1725.patch
        59 kB
        Uri Boness
      7. SOLR-1725.patch
        58 kB
        Erik Hatcher
      8. SOLR-1725.patch
        34 kB
        Erik Hatcher
      9. SOLR-1725.patch
        33 kB
        Erik Hatcher
      10. SOLR-1725.patch
        34 kB
        Erik Hatcher
      11. SOLR-1725.patch
        52 kB
        Hoss Man
      12. SOLR-1725.patch
        69 kB
        Hoss Man
      13. SOLR-1725.patch
        70 kB
        Hoss Man
      14. SOLR-1725.patch
        71 kB
        Hoss Man
      15. SOLR-1725.patch
        71 kB
        Hoss Man

        Activity

        Uri Boness created issue -
        Uri Boness made changes -
        Field Original Value New Value
        Attachment SOLR-1725.patch [ 12430671 ]
        Uri Boness made changes -
        Attachment SOLR-1725.patch [ 12430683 ]
        Uri Boness made changes -
        Attachment SOLR-1725.patch [ 12430690 ]
        Noble Paul made changes -
        Comment [
        Why are we limiting this to javascript . Why can't somebody use groovy/Scala/JRuby or whatever is supported by the the java6 scripting engine?

        ]
        Uri Boness made changes -
        Attachment SOLR-1725.patch [ 12430801 ]
        Uri Boness made changes -
        Attachment SOLR-1725.patch [ 12431217 ]
        Simon Rosenthal made changes -
        Attachment SOLR-1725-rev1.patch [ 12491563 ]
        Jan Høydahl made changes -
        Labels UpdateProcessor
        Fix Version/s 4.0 [ 12314992 ]
        Robert Muir made changes -
        Fix Version/s 4.1 [ 12321141 ]
        Fix Version/s 4.0 [ 12314992 ]
        Erik Hatcher made changes -
        Assignee Erik Hatcher [ ehatcher ]
        Erik Hatcher made changes -
        Attachment SOLR-1725.patch [ 12527887 ]
        Erik Hatcher made changes -
        Attachment SOLR-1725.patch [ 12528108 ]
        Erik Hatcher made changes -
        Attachment SOLR-1725.patch [ 12528125 ]
        Erik Hatcher made changes -
        Attachment SOLR-1725.patch [ 12528227 ]
        Hoss Man made changes -
        Attachment SOLR-1725.patch [ 12533930 ]
        Hoss Man made changes -
        Attachment SOLR-1725.patch [ 12534083 ]
        Hoss Man made changes -
        Attachment SOLR-1725.patch [ 12534313 ]
        Hoss Man made changes -
        Attachment SOLR-1725.patch [ 12534490 ]
        Hoss Man made changes -
        Attachment SOLR-1725.patch [ 12536152 ]
        Hoss Man made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Fix Version/s 4.0 [ 12322455 ]
        Fix Version/s 4.1 [ 12321141 ]
        Resolution Fixed [ 1 ]
        Erik Hatcher made changes -
        Resolution Fixed [ 1 ]
        Status Resolved [ 5 ] Reopened [ 4 ]
        Assignee Erik Hatcher [ ehatcher ]
        Erik Hatcher made changes -
        Priority Major [ 3 ] Critical [ 2 ]
        Robert Muir made changes -
        Fix Version/s 4.0 [ 12322551 ]
        Fix Version/s 4.0-BETA [ 12322455 ]
        Hoss Man made changes -
        Resolution Fixed [ 1 ]
        Status Reopened [ 4 ] Resolved [ 5 ]
        Assignee Hoss Man [ hossman ]
        Fix Version/s 5.0 [ 12321664 ]
        Fix Version/s 4.0-BETA [ 12322455 ]
        Fix Version/s 4.0 [ 12322551 ]
        Uwe Schindler made changes -
        Status Resolved [ 5 ] Closed [ 6 ]

          People

          • Assignee:
            Hoss Man
            Reporter:
            Uri Boness
          • Votes:
            10 Vote for this issue
            Watchers:
            13 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development