in

CodeSmith Community

Your Code. Your Way. Faster!

Arbitrary Limitation of DeepSessionInnerList Size to 300 Items (.netTiers v2.1.0.471)

Last post 04-17-2008 11:27 PM by kolsson. 3 replies.
Page 1 of 1 (4 items)
Sort Posts: Previous Next
  • 03-27-2007 12:07 PM

    • phurst
    • Not Ranked
    • Joined on 03-27-2007
    • Posts 2
    • Points 40

    Arbitrary Limitation of DeepSessionInnerList Size to 300 Items (.netTiers v2.1.0.471)

    I could not figure out why entities at the start of my list would save, but entities after row 30 would not.

    I eventually traced it to these lines in the AddRun method in EntityProviderBaseCode.generated.cs file:

    if (DeepSessionInnerList.Count > 300)

    CancelSession = true;

    Why is there an arbitrary limitation on the DeepSessionInnerList size? Why 300?

    Is there some sytemic way of turning this off, or is it just a bug?

    • Post Points: 35
  • 03-27-2007 12:22 PM In reply to

    Re: Arbitrary Limitation of DeepSessionInnerList Size to 300 Items (.netTiers v2.1.0.471)

    Well, that's means that it has recursively gone 300 levels, if it hits
    that point, there is likely an issue with it having to go that deep
    before it saves your entities. If you change it to say, 500, does it
    work?

    On 3/27/07, phurst wrote:
    >
    >
    > I could not figure out why entities at the start of my list would save, but
    > entities after row 30 would not.
    >
    > I eventually traced it to these lines in the AddRun method in
    > EntityProviderBaseCode.generated.cs file:
    >
    >
    > if (DeepSessionInnerList.Count > 300)
    >
    > CancelSession = true;
    >
    > Why is there an arbitrary limitation on the DeepSessionInnerList size? Why
    > 300?
    >
    > Is there some sytemic way of turning this off, or is it just a bug?
    >
    >
    >

    Robert Hinojosa

    -------------------------------------
    Member of the Codesmith Tools, .netTiers, teams

    http://www.nettiers.com
    -------------------------------------
    • Post Points: 65
  • 03-27-2007 4:36 PM In reply to

    • phurst
    • Not Ranked
    • Joined on 03-27-2007
    • Posts 2
    • Points 40

    Re: Arbitrary Limitation of DeepSessionInnerList Size to 300 Items (.netTiers v2.1.0.471)

    Ah! -- Thank you so much for the prompt and helpful reply Robert.

    I have not had this problem on previous projects, so obviously this was something to do with my table structure causing recursion. I looked again at the design. The salient difference from other cases is: I had a table (A) with two child tables (B, and C); table A had an integer PK; both tables B, and C had a 2-part composite PK one element of which was a FK to table A.

    I decided to change the table structure so that tables B and C have a simple integer identity PK column, and the columns in tables B and C that originally formed the PK become a unique index.

    Bingo! It works. No more deep recursion.

    Any idea why my original structure would cause this problem?

    • Post Points: 5
  • 04-17-2008 11:27 PM In reply to

    • kolsson
    • Not Ranked
    • Joined on 04-17-2008
    • Posts 3
    • Points 105

    Re: Arbitrary Limitation of DeepSessionInnerList Size to 300 Items (.netTiers v2.1.0.471)

    I've encountered this problem as well and our table structure in that regard was extremely simple.  A TList of parent entities and the relationship was in fact a 1:1 between the parent and the child and fell over after a few hundred netities. I suspect that it is the calculation of the recursion level or entity relationships  is incorrect. For now, our work-around is to do a DeepSave of no more than 200 entities.

    • Post Points: 5
Page 1 of 1 (4 items)
Copyright © 2008 CodeSmith Tools, LLC
Powered by Community Server (Commercial Edition), by Telligent Systems