locked
HTTP 504 querying a WCF Data Service with large number of rows RRS feed

  • Question

  • Hello

    This call should normally return more than 200'000 rows but I get a HTTP 504:
    http://localhost/Prices/CollectorFeed.svc/input_base_products()?$filter=base_product_id ne null

    However when I call this I should normally get about 42'000 rows and that works fine:
    http://localhost/Prices/CollectorFeed.svc/input_base_products()?$filter=base_product_id lt 2000

    I only have this problem when the services are hosted in IIS 6.1 on Windows XP x64 but on a Windows Server 2008 x64 machine running IIS 7.0 I don't get a HTTP 504.

    I believe that it is some kind of timeout because on my Windows XP sandbox I always get a HTTP 504 after appromixately 12 seconds whilst on the Windows Server 2008 machine ~ 30 seconds to return the feed.

    If this is a timeout issue, where should I increase this timeout and how?

    Many thanks in advance

    G.

    Tuesday, August 3, 2010 8:28 AM

Answers

  • I would probably still use SDP even in this case. The main reason is that having downloaded evertyhing in one big request has risks. What if the request fails/times out (network problem and so on). In that case the client would have to retry the whole thing. Having it split into multiple chunks will give you much finer retry capabilities. But it might be that it really doesn't matter in your case.

    I havent's seen this problem yet in this forum, but maybe somebody else did...

    Thanks,


    Vitek Karas [MSFT]
    Wednesday, August 4, 2010 8:15 AM
    Moderator

All replies

  • Hi,

    I would suggest you ask this question on IIS forums (as it's not really about WCF Data Services).

    In any case, this doesn't seem like the best design. Did you look at server driven paging to prevent such huge queries from running on the server?

    http://blogs.msdn.com/b/phaniraj/archive/2010/04/25/server-driven-paging-with-wcf-data-services.aspx

    Thanks,


    Vitek Karas [MSFT]
    Tuesday, August 3, 2010 8:36 AM
    Moderator
  • Hello

    We don't need paging for this service as it is used for synchronization purposes only. The entire process takes approximately 35 minutes and it is scheduled to run overnight.

    I will ask this question on the IIS forum but I was hoping that someone would have run into the same issue and would have found a workaround...

    G.

    Wednesday, August 4, 2010 8:07 AM
  • I would probably still use SDP even in this case. The main reason is that having downloaded evertyhing in one big request has risks. What if the request fails/times out (network problem and so on). In that case the client would have to retry the whole thing. Having it split into multiple chunks will give you much finer retry capabilities. But it might be that it really doesn't matter in your case.

    I havent's seen this problem yet in this forum, but maybe somebody else did...

    Thanks,


    Vitek Karas [MSFT]
    Wednesday, August 4, 2010 8:15 AM
    Moderator