Solr is not a database, even though some of the features introduced in Version 4 make it closer to one. Therefore, many production configurations involve having the master content stored in a database, and then copied into Solr and re-organized for faster searching.
DataImportHandler has strong support for importing data from the databases, both as a complete set and in incremental-delta mode.
Let's see how DIH makes importing data from a database easy.
We need to create a database first. We are going to use DerbyDB, which comes bundled with Java (and is called JavaDB), as the database is filesystem-based and also includes a built-in client. If your system does not have Derby installed, ...