Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Solr Wiki" for change 
notification.

The following page has been changed by NoblePaul:
http://wiki.apache.org/solr/DataImportHandler

------------------------------------------------------------------------------
  In order to get data from the database, our design philosophy revolves around 
'templatized sql' entered by the user for each entity. This gives the user the 
entire power of SQL if he needs it. The root entity is the central table whose 
primary key can be used to join this table with other child entities.
  
  == Commands ==
+  
+ The handler exposes all its API as http requests . The following are the 
possible operations
  
+  * '''full-import''' : Full Import operation can be started by hitting the 
URL `http://<host>:<port>/solr/dataimport?command=full-import`. This operation 
will be started in a new thread and the ''status'' attribute in the response 
should be shown ''busy'' now. Depending on the size of your data set, this 
operation may take some time. When full-import command is executed, it stores 
the start time of the operation in a file located at 
''conf/dataimport.properties''. This stored timestamp is used when a 
delta-import operation is executed.
+  * '''delta-import''' :  For incremental imports and change detection run the 
command `http://<host>:<port>/solr/dataimport?command=delta-import`
+  * '''status''' : To know the status of the current command , hit the URL 
`http://<host>:<port>/solr/dataimport` .It gives an elaborate statistics on 
no:of docs created, deleted, queries run, rows fetched , status etc
- === Using `full-import` command ===
- Full Import operation can be started by hitting the URL 
[http://localhost:8983/solr/dataimport?command=full-import]. This operation 
will be started in a new thread and the ''status'' attribute in the response 
should be shown ''busy'' now. Depending on the size of your data set, this 
operation may take some time. At any time, you can hit 
[http://localhost:8983/solr/dataimport] to see the status flag.
- 
- When full-import command is executed, it stores the start time of the 
operation in a file located at ''conf/dataimport.properties''. This stored 
timestamp is used when a delta-import operation is executed.
- 
- === Checking the status ===
- The request returns immedietly after trigggerring the command. To know the 
status of the current import , hit the URL 
[http://localhost:8983/solr/dataimport] 
- 
- It gives an elaborate statistics on no:of docs created, deleted, queries run, 
rows fetched , status etc
- 
- === Reload config ===
- If the data-config is changed and you wissh to reload the file without 
restarting Solr. eun the command 
[http://localhost:8983/solr/dataimport?command=reload-config] 
+  * '''reload-config''' : If the data-config is changed and you wissh to 
reload the file without restarting Solr. run the command 
`http://<host>:<port>/solr/dataimport?command=reload-config` 
+  * '''abort''' : Abort an ongoing opertaion by hitting the url 
`http://<host>:<port>/solr/dataimport?command=abort`
  
- === Full Import Example ===
+ == Full Import Example ==
  
  Let us consider an example. Suppose we have the following schema in our 
database
  

Reply via email to