: most of time seems to be used for the writer getting and writing the docs : can those docs prefetched?
as mentiond, the documentCache can help you out in the common case, but 1-4 seconds for just the XMLWriting seems pretty high ... 1) how are you timing this (ie: what exactly are you measuring) 2) how many stored fields do each of your documents have? (not how many are in your schema.xml, how many do each of your docs really have in them) ...having *lots* of stored fields can slow down retrieval of the Document (and Document retrival is delayed untill response writing) so if you have thousands thta night account for it. If you're use case is to only ever return the "ID" field, then not storing anything else will help keep your total index size smaller and should speed up the response writing. -Hoss