How to set source from input stream during creation of new indexes