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 FergusMcMenemie: http://wiki.apache.org/solr/DataImportHandler The comment on the change is: typo plus fixing camel case escaping ------------------------------------------------------------------------------ * The datasource configuration can be done in solr config xml [#solrconfigdatasource also] * The attribute 'type' specifies the implementation class. It is optional. The default value is `'JdbcDataSource'` * The attribute 'name' can be used if there are [#multipleds multiple datasources] used by multiple entities - * All other attributes in the <dataSource> tag are arbitrary. It is decided by the !DataSource implementation. [#jdbcdatasource See here] for attributes used by !JdbcDataSource and [#httpds see here] for !URLDataSource + * All other attributes in the <dataSource> tag are arbitrary. It is decided by the !DataSource implementation. [#jdbcdatasource See here] for attributes used by !JdbcDataSource and [#httpds see here] for URL!DataSource * [#datasource See here] for plugging in your own [[Anchor(multipleds)]] === Multiple DataSources === @@ -318, +318 @@ DataImportHandler can be used to index data from HTTP based data sources. This includes using indexing from REST/XML APIs as well as from RSS/ATOM Feeds. [[Anchor(httpds)]] - == Configuration of !URLDataSource == + == Configuration of URLDataSource == - A sample configuration in for !URLDataSource in data config xml looks like this + A sample configuration in for URL!DataSource in data config xml looks like this {{{ <dataSource type="URLDataSource" baseUrl="http://host:port/" encoding="UTF-8" connectionTimeout="5000" readTimeout="10000"/> }}} @@ -720, +720 @@ This is the defaut. The !DataSource must be of type `DataSource<Iterator<Map<String, Object>>>` . !JdbcDataSource can be used with this. === XPathEntityProcessor === - Used when indexing XML type data. The !DataSource must be of type `DataSourec<Reader>` . !URLDataSource or !FileDataSource is commonly used with !XPathEntityProcessor. + Used when indexing XML type data. The !DataSource must be of type `DataSourec<Reader>` . URL!DataSource or !FileDataSource is commonly used with X!PathEntityProcessor. === FileListEntityProcessor === A simple one which can be used to enumerate the list of files from a File System based on some criteria. It does not use a !DataSource. The entity attributes are: @@ -814, +814 @@ }}} === HTTPDataSource === - This datasource now deprecated in favor of !URLDataSource. There is no change in functionality between !URLDataSource and !HTTPDataSource, only a name change. + This datasource is now deprecated in favor of URL!DataSource. There is no change in functionality between URL!DataSource and !HTTP!DataSource, only a name change. === FileDataSource === - This can be used like an !URLDataSource but used to fetch content from files on disk. The only difference from !URLDataSource, when accessing disk files, is how a pathname is specified. The signature is as follows + This can be used like an URL!DataSource but used to fetch content from files on disk. The only difference from URL!DataSource, when accessing disk files, is how a pathname is specified. The signature is as follows {{{ public class FileDataSource extends DataSource<Reader> }}} @@ -829, +829 @@ === FieldReaderDataSource === <!> ["Solr1.4"] - This can be used like an !URLDataSource . The signature is as follows + This can be used like an URL!DataSource . The signature is as follows {{{ public class FieldReaderDataSource extends DataSource<Reader> }}} @@ -847, +847 @@ === ContentStreamDataSource === <!> ["Solr1.4"] - Use this to use the POST data as the DataSource. This can be used with any !EntityProcessor that uses a !DataSOurce<Reader> + Use this to use the POST data as the DataSource. This can be used with any !EntityProcessor that uses a !DataSource<Reader> == EventListeners == !EventListener can be registered for "onImportStart" and onImportEnd" .It must implement the interface [http://svn.apache.org/viewvc/lucene/solr/trunk/contrib/dataimporthandler/src/main/java/org/apache/solr/handler/dataimport/EventListener.java?view=markup EventListener]. @@ -896, +896 @@ There are 3 datasources two RDBMS (jdbc1,jdbc2) and one xml/http (B) * `jdbc1` and `jdbc2` are instances of type `JdbcDataSource` which are configured in the solrconfig.xml. - * `http` is an instance of type `URLDataSource` + * `http` is an instance of type `URL!DataSource` * The root entity starts with a table called 'A' and uses 'jdbc1' as the datasource . The entity is conveniently named as the table itself * Entity 'A' has 2 sub-entities 'B' and 'C' . 'B' uses the datasource instance 'http' and 'C' uses the datasource instance 'jdbc2' * On doing a `command=full-import` The root-entity (A) is executed first
