Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
20
Got "Server does not respond" when expanding a tree node
posted

When expanding a tree node, "Server does not respond" occurrs when the node has large volume of children folders. I tried the following workarounds:

Workaround 1: In the 8_igCallback.js, I increased the _timeout value for the ControlCallbackManager from 20000 to 120000 milliseconds (2 mins) but it didn't help.

Workaround 2: In the igWebDataTreeNode.js set_expanded function, I put a sleep(20000) function after tree._populateItem(this) and before returning. It seemed working but the entire UI got hold up. Another problem with this is that the node itself contains no other information except the node name via this.get_text(). If I want to add a condition before calling the sleep() (e.g. if this.childrenCount > 10, call sleep()), I will have to pass the count from the server side which is not possible after the first time page load.

Occasionally, it will only work with the combination of workaround 1 & 2.

I'm looking for a right place/way to tell the tree control to wait longer for a response. Thanks!

  • 10685
    Offline posted

    Hello Erica, 

    Thank you for posting in our community!

    I expect you are using load on demand to load the additional nodes when expanded and the server takes its time to send the data. When using big data and there is no way to display the data in other way to the user, but insist on using one WebDataTree to show all of it, it is a common practice to update the web.config file’s MaxHttpCollectionKeys and MaxJsonDeserializerMembers keys.

    I suggest setting these could at least ensure the server does not block the response if not else. 

    As these are Int32, it is possible to set a high value. For example, test with the following:
       <add key="aspnet:MaxHttpCollectionKeys" value="2000000" />
       <add key="aspnet:MaxJsonDeserializerMembers" value="2000000" /> 

    In case the above do not work for you, please let me know:

    • Are you by any chance using Update panel?
    • What is the version of the product you are using?
    • Can you share a code sample of your approach?
       

    Related: Deserialization failure when we use load-on-demand in WebDataTree