VMware Cloud Community
ChandraSekhar19
Contributor
Contributor

SearchDatastore_Task in vSphere CLI.

When i have started using SearchDatastore_Task and CopyDatastoreFile_Task for advantage of asynchronous functioning, i have come to know that these are still being created as a blocking calls(like the Synchronous calls where it is expecting to return a message of what has happened to the initiated action on Server side.)

My objective is like to copy a file using the vSphere CLI to all of the datastores on ESX. So in this process if any of the datastore is un-accessible (mean to say if datastores physical space is removed at root level instead deleting it from the ESX level.) it was hanging long time and saying that this datastore is not accessible or un-able to copy. This is fine as the call i have used is a synchronous call(CopyDatastoreFile), and i want to error it out much before with out waiting for long time using the asynchrounous call of the same function.

Even the behaviour is same when i want to browse a datastore which is not accessible using SearchDatastore_Task.

Do any body see the same scenarion with these call?

If not and if these calls are working as asynchronous functions kindly let me know a sample to use.

Thank you.

Chandra Sekhar P

0 Kudos
0 Replies