From: Adam R. <ad...@ex...> - 2012-02-25 14:06:22
|
Okay so I am mystified! Here is how I am trying to reproduce the error - Windows XP SP3, Oracle JDK6 1.6.0_20-b02. I have a fresh checkout of eXist-db trunk. I have built it with build.bat. I have then started the Java Admin client in embedded mode (to reduce the number of moving parts). I restore the database backup that you provided, and run the Query view in the Java Admin Client. I run your XQuery over and over again by clicking the submit button. I cannot see any increased memory use, in fact I run out of disk space from the temporary files created (after running the query enough to generate 6GB of temp files) before anything else happens. I will address the issue of temporary files not being removed on Window separately. I have also modified MemoryMappedFileInputStreamCache.java to produce CSV output on the console about the memory use before and after each invocation of the memory mapping. I then plotted this as a line graph in Excel to make sure the memory use was constant. I attach the modified MemoryMappedFileInputStreamCache.java which will produce the CSV output, and also a .xls of the results and Chart I created (I checked and you can also open this in OpenOffice or LibreOffice). Perhaps you could repeat the above process using the modified Java file, and tell me if you see different results? or perhaps there is something different about how you perform the test than I am and you can tell me what I am doing wrong here? I really want to solve this issue. Do you have anyway for me to remotely access the test machine where you are seeing these issues, so that I may debug it there? Thanks Adam. On 10 January 2012 14:01, Ron Van den Branden <ron...@ka...> wrote: > Hi, > > This question relates to eXist-trunk (rev. 15640). When I try to zip a > collection of binary resources stored in my db with the compression:zip() > function, I'm hitting error messages like: > > An exception occurred during query execution: Error while evaluating > expression: > util:binary-doc('/db/test/jqueryui/smoothness/images/ui-bg_glass_95_fef1ec_1x400.png'). > Map failed [at line 7, column 8, source: String] [at line 7, column 8] > > I'll attach the full stack trace from the logs in a separate file > (mapFailed.log). I'll attach as well a test collection with which I've been > able to reproduce the error, as explained below. > > I've tried to track down the triggering code, and think util:binary-doc() is > involved. This is how I am constructing the entries for the zip file (note: > the /db/test collection only contains (nested collections with) binary > docs): > > for $a in collection('/db/test') > let $uri := xs:anyURI(document-uri($a)) > return<entry name="{$uri}">{util:binary-doc($uri)}</entry> > > This code run against the test collection attached produces the error. > Strangely enough, the error isn't thrown consistently: sometimes the query > succeeds, sometimes it doesn't. > > I have no clue what 'map failed' points at, but it seems to be a low-level > Java error, and I see no reason why the query would throw it. Is it the > resources' nesting depth, file names, file contents, the for loop? Or is > this not the way to loop over a collection with binary resources? Can anyone > help me out, please? > > Kind regards, > > Ron > > -- > Ron Van den Branden > Wetenschappelijk attaché / Senior Researcher > Reviews Editor LLC. The Journal of Digital Scholarship in the Humanities > > Centrum voor Teksteditie en Bronnenstudie - CTB (KANTL) > Centre for Scholarly Editing and Document Studies > Koninklijke Academie voor Nederlandse Taal- en Letterkunde > Royal Academy of Dutch Language and Literature > Koningstraat 18 / b-9000 Gent / Belgium > tel: +32 9 265 93 51 / fax: +32 9 265 93 49 > E-mail : ron...@ka... > http://www.kantl.be/ctb > > > ------------------------------------------------------------------------------ > Write once. Port to many. > Get the SDK and tools to simplify cross-platform app development. Create > new or port existing apps to sell to consumers worldwide. Explore the > Intel AppUpSM program developer opportunity. appdeveloper.intel.com/join > http://p.sf.net/sfu/intel-appdev > _______________________________________________ > Exist-open mailing list > Exi...@li... > https://lists.sourceforge.net/lists/listinfo/exist-open > -- Adam Retter eXist Developer { United Kingdom } ad...@ex... irc://irc.freenode.net/existdb |