lucene-solr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ryan McKinley (JIRA)" <j...@apache.org>
Subject [jira] Updated: (SOLR-85) [PATCH] Add update form to the admin screen
Date Tue, 20 Feb 2007 09:09:05 GMT

     [ https://issues.apache.org/jira/browse/SOLR-85?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Ryan McKinley updated SOLR-85:
------------------------------

    Attachment: SOLR-85-UpdatForms-RequestHandlers.patch

> 
> 1) duplicate code cut/paste from CommitRequestHandler in XmlUpdateRequestHandler 

I moved the common code to a new file RequestHandlerUtils.java


> 2) the upload form assumes /update/xml is a registered requestHandler name which...

I may have gone completely mad with this one, so a sanity check would be  good!  

I made a "FormRequestHandler" that returns an HTML form for a given path if it has been registered.
 For example, if you had:

 <requestHandler name="/admin/form" class="...FormRequestHandler" >
   <lst name="invariants">
    <str name="wt">raw</str> 
   </lst>
   <lst name="forms">
    <str name="/update/xml">forms/update/xml.html</str> 
    <srr name="/update/csv">forms/update/csv.html</str> 
   </lst>
 </requestHandler>

hitting:
 http://localhost:8983/solr/admin/form?path=/update/xml

returns the html sitting in ${solr.home}/conf/forms/update/xml.html

It replaces ${path} with the registered path.

- - - - - - -

Since the admin RequestHandler config scheme gets pretty unruly if you have to configure it
is solrconfig.xml, I added a flag to the <admin> section to set where you want all the
standard ones

<admin>
  <registerStandardHandlers>/admin</registerStandardHandlers>
  ...
</admin>

If you put "false" it will not register the default paths.  It will not overwrite any existing
paths either.  that is, if you manually register,  "/admin/file" it will not put in the default
one


- - - - - 

The AdminHandlersSetupHelper automatically finds forms in the conf/forms/ directory that match
registered handlers and registers them with the FormRequestHandler.  

- - - - - -

I'm putting this up mostly for a sanity check.  If you like the direction, i'll add more comments,
documentation and clean things up.

thanks

> [PATCH] Add update form to the admin screen
> -------------------------------------------
>
>                 Key: SOLR-85
>                 URL: https://issues.apache.org/jira/browse/SOLR-85
>             Project: Solr
>          Issue Type: New Feature
>          Components: update
>            Reporter: Thorsten Scherler
>         Attachments: solar-85.png, solar-85.png, solar-85.with.file.upload.diff, solar-85.with.file.upload.diff,
solar-85.with.file.upload.diff, solar-85.with.file.upload.diff, SOLR-85-UpdatForms-RequestHandlers.patch,
solr-85-with-104.patch, solr-85-with-104.patch, solr-85-with-104.patch, solr-85.diff, solr-85.diff,
solr-85.FINAL.diff
>
>
> It would be nice to have a webform to update solr via a http interface instead of using
the post.sh.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message