Changing order of parameters
Improve handling of unloads
Add option to use non default index server