Last post Aug 29, 2014 06:56 AM by artsnob
Aug 28, 2014 06:29 PM|artsnob|LINK
I have run into an ultra-frustrating XML problem with a web application I developed. I cannot duplicate it off-line, but it keeps recurring once it's published.
The application deals exclusively with XML data. A gridview is tied to an XMLdatasource control, and displays information from two different sets of XML data. It works beautifully with either dataset when you first publish it. However, after it's been
up for about a day, it suddenly stops working with one of the datasets. Here's what really confounds me: you can make it start working again just by overwriting one of the XML files with an exact duplicate. The program and data are both identical to when
it wasn't working -- so why WASN'T it working?
It would certainly seem to be environmental (pool memory, file handles, etc.). Has anyone ever experienced something like this before? Someone suggested tweaking sessionstate in web.config but couldn't tell me how. It's going to take an XML genius to
figure this one out. Anyone?
Is there a way to PROGRAMATICALLY trigger whatever happens when a hung file is deleted and then re-written? Inelegant, but it would solve my problems.
Is there an article available on best practices for caching and web.config customization for web apps that ONLY draw on static XML data? If we're talking less than a meg spread out over seven files, should the data be cached at the beginning of the app?
Aug 29, 2014 05:26 AM|De_rry|LINK
According to your description, Perhaps the XML file is damaged or removed due to some unfriendly operations. So you should check the XML file on your server when your application stop working.
If you have any question about this matter, please post back freely.
Aug 29, 2014 06:56 AM|artsnob|LINK
I'm 100% certain that the file is not damaged and is identical to the XML file I overwrite it with. I can copy it back to my local server and it works. I can also FTP it to a temporary location, erase it, FTP it back, and it works.
I'm beginning to think that the problem is due to a complex transform file I'm using that somehow consumes memory every time it's used and never releases it until the file is erased or overwritten. It employs this parameter:
Dim xsltArgs As New XsltArgumentList()
xsltArgs.AddParam("films", "", films.CreateNavigator().Select("/"))
Me.xmlSCHEDULE.TransformArgumentList = xsltArgs
Could createnavigator() be the culprit? I have other XML files that fill the same gridview under different
circumstances that don't need the addparam or transformargumentlist lines and I never have any problem with them.