Raven performance problem using dynamic indexes and replication

54 views
Skip to first unread message

stephen...@googlemail.com

unread,
Oct 19, 2017, 10:21:23 AM10/19/17
to RavenDB - 2nd generation document database
Hi.
I am using RavenDB build #3800.
I have 2 databases setup on 2 separate servers which have 2-way replication setup between them.
The database in question has a document count of 7805 and most of the documents are around 70kb in size.
I am using Raven as the database for an ASP.NET application.  

I have been having a few problems when making some changes.  I have updated two of the indexes with a dynamic index.
eg.
_ = p.Prices.Select(x => CreateField("Price_" + x.Account, x.Price) ?? 0)

When I first tried to deploy these changes, the 2 indexes started rebuilding on the first database and then started on the 2nd database straight away as index replication was enabled.  I left these for about an hour but they never completed.  Raven was using 100% of the CPU and most of the memory on both servers.  

I managed to get around this problem by disabling index replication which worked perfectly.  However a few hours later I started an application which reads and bulk inserts nearly all of the documents in the database.  When I tested this on a database without replication enabled, Raven used 100% CPU while it was inserting and then went back down to normal levels (around 0-10%) which is fine.  However, doing this on the database with replication caused Raven to use all of the CPU and memory and continue using all of the CPU after the insert had finished.  Eventually both Raven servers crashed and I couldn't access them through Raven Studio and all requests were timing out.  I had to manually restart the Raven service on both servers in order to get them back to normal.

I presume this is something to do with replication being enabled but could be wrong.

If anybody has any advice or suggestions it would be greatly appreciated.

Thanks.

Michael Yarichuk

unread,
Oct 19, 2017, 11:08:00 AM10/19/17
to RavenDB - 2nd generation document database
Hi,
Build 3800 is approximately 2 year old. Since then we had performance optimizations and fixes for similar symptoms. Is it possible for you to update RavenDB version?

--
You received this message because you are subscribed to the Google Groups "RavenDB - 2nd generation document database" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ravendb+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
Best regards,

 

Hibernating Rhinos Ltd  cid:image001.png@01CF95E2.8ED1B7D0

Michael Yarichuk l RavenDB Core Team 

Office: +972-4-622-7811 l Fax: +972-153-4-622-7811

 

RavenDB paving the way to "Data Made Simple"   http://ravendb.net/  

Oren Eini (Ayende Rahien)

unread,
Oct 19, 2017, 4:10:47 PM10/19/17
to ravendb
There are a few issues with index replication that can cause it to ping back between servers that has been long fixed.
Start with upgrading to the latest release and see if this resolves the issue

Hibernating Rhinos Ltd  

Oren Eini l CEO Mobile: + 972-52-548-6969

stephen...@googlemail.com

unread,
Oct 23, 2017, 6:40:23 AM10/23/17
to RavenDB - 2nd generation document database
Thanks.  We will try updating to the latest version first and see if that helps.
Reply all
Reply to author
Forward
0 new messages