Hi Sanj, that code runs synchronously, so the indexing will be finished when your method completes.
If this is asp.net code then that might be a problem, because if there are a lot (hundred or more) of documents it will take non trivial time and could timeout the request.
Do you know how to run code asynchronously with Task?
There is also this way to add documents asynchronously but its only for one document at a time
https://keyoti.com/produ...porting.htm#incremental
Jim
-your feedback is helpful to other users, thank you!