Query paging is little bit slowly

35 views
Skip to first unread message

Nguyễn Huy

unread,
Jul 27, 2015, 10:05:07 PM7/27/15
to RavenDB - 2nd generation document database
Hi all,

I have a query below and I have almost 1m2 records. But when change to another page it take 0.5s to display that record. Is there anyway to improve the performace. i only set 20 record for each page

 results = Session.Query<Product_Search.Result, Product_Search>().Search(x => x.Query,
                        searchString.GetQueryProduct(searchString), escapeQueryOptions: EscapeQueryOptions.AllowAllWildcards,
                        options: SearchOptions.And).Statistics(out stats).Skip((page - 1) * limit).Take(limit).As<ProductModel>().ToList();

Thank and Regards,

Huy Nguyen

Michael Yarichuk

unread,
Jul 28, 2015, 1:13:58 AM7/28/15
to RavenDB - 2nd generation document database
Can you show fiddler output of this query?

--
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+u...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
Best regards,

 

Michael Yarichuk

RavenDB Core Team

Tel: 972-4-6227811

Fax:972-153-4-6227811

Email : michael....@hibernatingrhinos.com

 

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

Nguyễn Huy

unread,
Jul 28, 2015, 1:35:32 AM7/28/15
to rav...@googlegroups.com
Hi ,

PFA

--
You received this message because you are subscribed to a topic in the Google Groups "RavenDB - 2nd generation document database" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/ravendb/zbbXz1HxKqY/unsubscribe.
To unsubscribe from this group and all its topics, send an email to ravendb+u...@googlegroups.com.
save.PNG

Oren Eini (Ayende Rahien)

unread,
Jul 28, 2015, 2:36:15 AM7/28/15
to ravendb

Please send the saz file

Nguyễn Huy

unread,
Jul 28, 2015, 3:24:20 AM7/28/15
to rav...@googlegroups.com
Hi,

PFA ,


test.saz

Grisha Kotler

unread,
Jul 28, 2015, 3:49:45 AM7/28/15
to rav...@googlegroups.com
Each request to RavenDB took ~130ms.

Is this a web app that is connecting to a remote server?

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

Grisha Kotler l RavenDB Core Team Developer Mobile: +972-54-586-8647

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

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

Nguyễn Huy

unread,
Jul 28, 2015, 3:54:31 AM7/28/15
to rav...@googlegroups.com
Yes 

Nguyễn Huy

unread,
Jul 28, 2015, 4:01:59 AM7/28/15
to rav...@googlegroups.com
is anything wrong with that server ?

2015-07-28 14:49 GMT+07:00 Grisha Kotler <gri...@hibernatingrhinos.com>:

Oren Eini (Ayende Rahien)

unread,
Jul 28, 2015, 4:20:01 AM7/28/15
to ravendb
No, you are seeing good response times from the server.

Hibernating Rhinos Ltd  

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

Nguyễn Huy

unread,
Jul 28, 2015, 4:20:47 AM7/28/15
to rav...@googlegroups.com
Ok and about paging. It is ok right ?

Michael Yarichuk

unread,
Jul 28, 2015, 4:20:52 AM7/28/15
to RavenDB - 2nd generation document database
What is network latency between client and RavenDB hosting server?

Nguyễn Huy

unread,
Jul 28, 2015, 4:24:13 AM7/28/15
to rav...@googlegroups.com
PFA
save.PNG

Oren Eini (Ayende Rahien)

unread,
Jul 28, 2015, 4:27:52 AM7/28/15
to ravendb
Put a stop watch around your query, how long does this take from your code? Because from the server POV, everything is fine

Nguyễn Huy

unread,
Jul 28, 2015, 4:42:12 AM7/28/15
to rav...@googlegroups.com
Thank oren 

Kijana Woodard

unread,
Jul 28, 2015, 9:45:56 AM7/28/15
to rav...@googlegroups.com
What is the story for deep paging with 3.0?

From: Nguyễn Huy
Sent: ‎7/‎28/‎2015 3:42 AM
To: rav...@googlegroups.com
Subject: Re: [RavenDB] Query paging is little bit slowly

[The entire original message is not included.]

Oren Eini (Ayende Rahien)

unread,
Jul 28, 2015, 9:47:49 AM7/28/15
to ravendb
There isn't much, but we do have to do some work on the entire dataset until the page in question.
When you page to page #100000, that can get expensive.

Kijana Woodard

unread,
Jul 28, 2015, 10:26:51 AM7/28/15
to rav...@googlegroups.com
IIRC paging slowed down for me ~100. The case I was using it for is now best done by Streaming or Data Subscriptions. I've never seen a user get that deep in pages.

Oren Eini (Ayende Rahien)

unread,
Jul 28, 2015, 10:27:57 AM7/28/15
to ravendb
Were you doing distinct, or something like that?

Kijana Woodard

unread,
Jul 28, 2015, 10:40:39 AM7/28/15
to rav...@googlegroups.com
Not that I remember. I think this was 2.0 time frame.

Kijana Woodard

unread,
Jul 28, 2015, 10:46:02 AM7/28/15
to rav...@googlegroups.com
Found the thread where I mentioned my "issue". I was on page ~3000. :-)

Reply all
Reply to author
Forward
0 new messages