turquoiseowl / i18n

Smart internationalization for ASP.NET
Other
556 stars 155 forks source link

Memory leaks #391

Closed tomasr78 closed 3 years ago

tomasr78 commented 4 years ago

Recently our web application started to throw out of memory and crashing IIS app pool. While investigating we have found that the cause of high memory usage is i18n. It generates about 500K of strings in our case which then moved to Large Objects Head, the LOH becomes extremely large and eventually, we get the app tool crash. The stack trace of the problematic methods is below. Is this known issue or somehow related to our app?

image

p.s. we using the latest version 2.1.15. We could share the dump file if needed.

turquoiseowl commented 4 years ago

Hmm, first I've heard of this.

I've just done a quick review and it looks like TranslationItem.References collection is only appended to during PostBuild. Is the site static or are you doing on-the-fly updates to the content?

Further, is 500K necessarily that many strings? How big is the site? How much RAM does that translate to? WHat does the string count start at? How long does it take to grow to 500K?

vhatuncev commented 4 years ago

@tomasr78 just wondering, did you solve the issue? How do you think it's possible to reproduce this issue? I think to create a page with 500K records to translate and see the memory state.

turquoiseowl commented 3 years ago

Closing for now. Please re-open if still an issue.