[Mono-list] XmlSerializer
Willem.Smit@sanlam.co.za
Willem.Smit@sanlam.co.za
Thu, 20 May 2004 08:31:47 +0200
Hi guys
This mail is not mono related, but it is .Net related. The reason why I=
'm
mailing you guys is that you probably know better than any of the Micro=
soft
consultants we have here in this place and I'm sure you won't ask me $2=
000
just so I could ask you a question.
We put down a single sign-on solution here at work, using a
java/websphere/s370 backend and a .Net /c#/COM/ASP frontend. The back-e=
nd
works beautifully, but the appservers that the front-end runs on fall o=
ver
every 4-5 hours depending on load.
Looking at the performance counters on the box we can see that everytim=
e a
user logs on using this solution, 7 assemblies gets added to the total
assemblies and current assemblies counters. The number of current
assemblies currently loaded on our box (snapshot) is 151470.
I've isolated the code that creates these 7 assemblies everytime - it
happens during a call to the Serialize method of the XmlSerializer.
Now with a small little test project that serializes a simple class wit=
h a
few string properties, the first time you call Serialize on XmlSerializ=
er 7
assemblies get created. The difference here is during the next call to
Serialize no more assemblies are added, it's like XmlSerializer realise=
s
it's allready built objects to serialize objects of that specific type
allready, which in my mind seems like the right thing.
Now my question to you is twofold.
1. What is supposed to happen when you call the Serialize method on
XmlSerializer ?
- Do you know of a reason why XmlSerializer would create 7 assemb=
lies
every time and not reuse the previous objects it built to Serialize ?
2. Is this even a problem ? I mean the performance counter says there a=
re
151470 assemblies loaded into memory, but there is still more than enou=
gh
memory on the boxes, it's just that every four hours things
start going haywire on the servers and single sign-on is the only thing=
that's changed on the boxes. So we're thinking it's because of the reas=
on
above, but it might be totally unrelated... I'm really not sure
I'm in dire straights here guys, and I know this shouldn't bother you
because it's MS related, but I really would appreciate any help.
Thanx
Willem Smit
SL IT
***************
Any views expressed in this message are those of the individual sender,=
and
Sanlam accepts no liability therefore, except where the sender specific=
ally
states them to be those of Sanlam.
Enige sienswyses of stellings wat in hierdie boodskap uitgedruk word is=
di=E9
van die individuele afsender, en Sanlam aanvaar geen aanspreeklikheid
daarvoor nie, behalwe waar die afsender uitdruklik vermeld dat dit di=E9=
van
Sanlam is.
=