0

I want to create a database web publisher.

Solr search functionnalities suit perfectly to my needs (faceted search, full text search, etc...).

My problem is that I need data to be synchronised on the net.

I read that MySQL database have to be imported in Solr.

I plan to work with one source MSSQL database, replicated on a MySQL database on a web server. I need to use Solr on this database.

Is there a solution so that the changes on the replicated SQL database can be automatically echoed on the Solr index? I don't want to import the whole database each time it is modified, it would make my product complicated to use.

Thank you.

Jayendra
  • 52,349
  • 4
  • 80
  • 90

2 Answers2

0

you don't need to index the full db each time, that is what Delta import is for. You just configure it to import deltas at the times you need.

Persimmonium
  • 15,593
  • 11
  • 47
  • 78
0

You can use DataImportScheduler to keep your data synchronized. That's the most common way to keep Solr index in sync.

There are other ways, you could setup a trigger in your db to fire Solr's REST service that would reflect changes for all inserted/updated/deleted documents.

Also, since db is (commonly) used to handle some application, you could setup a Filter (javax.servlet for Java web apps) to intercept requests and push them to Solr before they even reach database.

Marko Bonaci
  • 5,622
  • 2
  • 34
  • 55
  • Ok thank you for your answers I will explore those solutions! The idea of a filter is interresting but in my case, the data changes are executed on the client server database (because clients manage database, and they publicate it, but they need to filter the information publicated before it is on the net), and than replicated on the web server database, which will use the solr application. So I don't think it will be usefull here. I will try DataimportScheduler. – user1537647 Jul 20 '12 at 08:45