Your question is how to index one million xml-files with solr.
You can use the bin/post-tool even with recursiv folder structure.
If this has enough functionality: fine. If you need more special features build your own indexer, in particular with solrj this is quite easy.
If you have enough main memory you can use DataImportHandler
with FileListEntityProcessor. ´FileListEntityProcessor´ first collects all files and than run through the real indexing. So in your case the first step will put one million instances of "File" in your main memory.