You are viewing a plain text version of this content. The canonical link for it is here.
Posted to xindice-users@xml.apache.org by Rob Redmon <Ro...@noaa.gov> on 2004/06/08 00:59:01 UTC
xpath optimization
Hi,
I'm wondering if anyone has any good performance/tuning notes.
My scenario is thus: I have need to build out a system that will manage
on order of 2000 docs spread across 50 or so different collection paths
and each doc having a nominal size of 30kbytes (as text file).
Fragments of each doc will be exposed to a JSP front end mimicing a
simple search engine. The docs will probably all adhere to the same schema.
Maybe someone has some advice/notes/links/books they've liked on
anything related, including topics like xpath, indexing, xsl, Java best
practices, etc... I'm new to xpath, so apologies in advance for any
iodiotic questions.
Maybe this isn't a question for here, I guess maybe it's more of
something I need to learn about xpath or the xmldb API.
I've been running into OutOfMemory exceptions when the result of an
xpath query (via the Java API) is going to be fairly large (probably the
result would be a few MB if stored as a xml text file) and so I'm
wondering if there is some better tuning that I can do or better useage
of XpathQueryService...
Thanks a bunch for any thoughts!
Rob
Re: xpath optimization
Posted by Vadim Gritsenko <va...@reverycodes.com>.
Rob Redmon wrote:
> Maybe this isn't a question for here, I guess maybe it's more of
> something I need to learn about xpath or the xmldb API.
> I've been running into OutOfMemory exceptions when the result of an
> xpath query (via the Java API) is going to be fairly large (probably
> the result would be a few MB if stored as a xml text file) and so I'm
> wondering if there is some better tuning that I can do or better
> useage of XpathQueryService...
First of all, avoid large files (see FAQ). If you can't live without
large files (can't refactor into small files), please keep in mind that
Xindice needs to have whole file in-memory in order to work on it
(xupdate, xpath, etc). This means, that you have to give server enough
memory (java options -Xmx, -Xms) to keep necessary amount of such
documents in memory.
Vadim