Here is one quick tutorial to Send some movie data (netflix oData format) to solr for indexing, and do some basic querying.
Sample Dataset, http://odata.netflix.com/Catalog/
I picked up 5 fields and put them into the solr scheme.xml,
then add solrnet to your C# client, Define one POCO object used for the mapping. use the solrxxx attirbute will enable you bridge some naming conventions between solr schema and your C# obejct.
then use OData Helper, and Linq entitiy to load the data (using .net framework 4.0)
once it download the catalog, several parallel tasks will be created to post the data to solr for indexing, after done, you can see the data is there,
notes,
solrnet using the Microsoft.Practices.ServiceLocation.dll as a dependency to manage the object creation,
you can use nuget search Odata to download the Odata helper.
Thursday, March 22, 2012
Apache Solr and SolrNet quickstart, using the Netflix Dataset (Odata format)
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment