Ah cool! Hope it works for you!
MArk On Thu, Apr 4, 2013 at 12:05 PM, Brian G <brian-goo...@vfive.com> wrote: > > That is where I'm doing it - but I wanted to test in prod that reloading > the XML did indeed fix the problem, and it did. > > Here's what I wound up with in XMLFileReader.cfc: > > try > { > results.addAll(xmlSearch(collection[counter], arguments.xpath)); > } > catch (any ex) > { > // flush the XML and try again > setXMLCollection(arrayNew(1)); > path = listToArray(getPathList()); > > for (p in path) > { > addXML(p); > } > > writeLog(type="Error", file="transfer-xml", text="Failed to > XmlSearch(#arguments.xpath#) in XMLFileReader.cfc, reloaded > #arrayLen(path)# XML Files, trying again against > #arrayLen(getXMLCollection())# loaded configurations... [#ex.type#] > #ex.message#"); > > // now re-search the XML > results.addAll(xmlSearch(collection[counter], arguments.xpath)); > } > > I think that will do the trick for this particular issue. I mean, it will > work around whatever is really going on, at least for now. Fingers crossed. > > > > On Wednesday, April 3, 2013 2:32:13 PM UTC-7, Mark Mandel wrote: > >> Why not do the try catch in here: >> http://transfer.riaforge.org/**index.cfm?event=page.svnview&** >> path=%2Ftransfer%2Ftrunk%**2Fcom%2Fio&file=XMLFileReader%**2Ecfc<http://transfer.riaforge.org/index.cfm?event=page.svnview&path=%2Ftransfer%2Ftrunk%2Fcom%2Fio&file=XMLFileReader%2Ecfc> >> >> LIne 42 of the search? >> >> Rather than outside? >> >> Mark >> >> >> On Thu, Apr 4, 2013 at 3:30 AM, Brian G <brian-...@vfive.com> wrote: >> >>> >>> On Tuesday, April 2, 2013 8:47:51 PM UTC-7, Mark Mandel wrote: >>>> >>>> Try/catch inside the XMLFileReader - if it overflows, then load up the >>>> path again. It knows where the XML file is, so it can always try it again. >>>> <http://www.2ddu.com/> >>>> >>> >>> That did it... on my wedged future production server, first I ran the >>> code that generated the stack overflow - still failed. Then I ran this: >>> >>> >>> <cfset orm = application.cs.getBean("**ormService") /> >>> <cfset xmlFileReader = orm.getTransfer().**getObjectManager().** >>> getObjectDAO().**getConfigReader() /> >>> <cfdump var="#arrayLen(xmlFileReader.**getXMLCollection())#" >>> label="pre-reload, num of xml files" /> >>> <cfset >>> xmlFileReader.addXML('/var/**www/pukka/main-prod/config/**transfer/transfer.xml', >>> true) /> >>> <cfdump var="#arrayLen(xmlFileReader.**getXMLCollection())#" >>> label="post-reload, num of xml files" /> >>> >>> Then I re-ran the borked code and actually it still failed. The >>> overwrite flag true here doesn't overwrite it only prepends to the array of >>> XML files so the search still failed when it hit the original, somehow >>> jacked up, XML file. I manually killed it with >>> arrayDeleteAt(**getXMLCollection(), >>> 2) and then re-ran my error-generating code and it worked fine. >>> >>> I'm not sure how to report this... clearly something is fubar'd and it >>> looks like a bug in CF but it's not reproducible in the traditional sense. >>> For now, I'm going to wrap the xmlsearch with a try/catch and see if that >>> works? >>> >>> Thanks for the help Mark. >>> >>> >>> -- >>> -- >>> Before posting questions to the group please read: >>> http://groups.google.com/**group/transfer-dev/web/how-to-** >>> ask-support-questions-on-**transfer<http://groups.google.com/group/transfer-dev/web/how-to-ask-support-questions-on-transfer> >>> >>> Try out the new Transfer ORM Custom Google Search: >>> http://www.google.com/cse/**home?cx=002375903941309441958:**2s7wbd5ocb8<http://www.google.com/cse/home?cx=002375903941309441958:2s7wbd5ocb8> >>> >>> You received this message because you are subscribed to the Google >>> Groups "transfer-dev" group. >>> To post to this group, send email to transf...@googlegroups.com >>> To unsubscribe from this group, send email to transfer-dev...@** >>> googlegroups.com >>> >>> For more options, visit this group at http://groups.google.com/** >>> group/transfer-dev?hl=en<http://groups.google.com/group/transfer-dev?hl=en> >>> >>> --- >>> You received this message because you are subscribed to the Google >>> Groups "transfer-dev" group. >>> To unsubscribe from this group and stop receiving emails from it, send >>> an email to transfer-dev...@**googlegroups.com. >>> >>> For more options, visit >>> https://groups.google.com/**groups/opt_out<https://groups.google.com/groups/opt_out> >>> . >>> >>> >>> >> >> >> >> -- >> E: mark....@gmail.com >> >> T: http://www.twitter.com/**neurotic <http://www.twitter.com/neurotic> >> W: www.compoundtheory.com >> >> 2 Devs from Down Under Podcast >> http://www.2ddu.com/ >> > -- > -- > Before posting questions to the group please read: > > http://groups.google.com/group/transfer-dev/web/how-to-ask-support-questions-on-transfer > > Try out the new Transfer ORM Custom Google Search: > http://www.google.com/cse/home?cx=002375903941309441958:2s7wbd5ocb8 > > You received this message because you are subscribed to the Google Groups > "transfer-dev" group. > To post to this group, send email to transfer-dev@googlegroups.com > To unsubscribe from this group, send email to > transfer-dev+unsubscr...@googlegroups.com > For more options, visit this group at > http://groups.google.com/group/transfer-dev?hl=en > > --- > You received this message because you are subscribed to the Google Groups > "transfer-dev" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to transfer-dev+unsubscr...@googlegroups.com. > For more options, visit https://groups.google.com/groups/opt_out. > > > -- E: mark.man...@gmail.com T: http://www.twitter.com/neurotic W: www.compoundtheory.com 2 Devs from Down Under Podcast http://www.2ddu.com/ -- -- Before posting questions to the group please read: http://groups.google.com/group/transfer-dev/web/how-to-ask-support-questions-on-transfer Try out the new Transfer ORM Custom Google Search: http://www.google.com/cse/home?cx=002375903941309441958:2s7wbd5ocb8 You received this message because you are subscribed to the Google Groups "transfer-dev" group. To post to this group, send email to transfer-dev@googlegroups.com To unsubscribe from this group, send email to transfer-dev+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/transfer-dev?hl=en --- You received this message because you are subscribed to the Google Groups "transfer-dev" group. To unsubscribe from this group and stop receiving emails from it, send an email to transfer-dev+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.