- Updated vmware/govmomi godep (Needs for vsan support)

- Fix unmount for vsanDatastore
- Add support for vsan datastore
This commit is contained in:
Abrar Shivani
2016-07-18 23:20:30 -07:00
parent 2301ab7e0e
commit 87e7535e94
31 changed files with 658 additions and 200 deletions

View File

@@ -17,26 +17,14 @@ limitations under the License.
package object
import (
"fmt"
"github.com/vmware/govmomi/vim25"
"github.com/vmware/govmomi/vim25/methods"
"github.com/vmware/govmomi/vim25/mo"
"github.com/vmware/govmomi/vim25/types"
"golang.org/x/net/context"
)
type ResourcePool struct {
Common
InventoryPath string
}
func (p ResourcePool) String() string {
if p.InventoryPath == "" {
return p.Common.String()
}
return fmt.Sprintf("%v @ %v", p.Common, p.InventoryPath)
}
func NewResourcePool(c *vim25.Client, ref types.ManagedObjectReference) *ResourcePool {
@@ -45,17 +33,6 @@ func NewResourcePool(c *vim25.Client, ref types.ManagedObjectReference) *Resourc
}
}
func (p ResourcePool) Name(ctx context.Context) (string, error) {
var o mo.ResourcePool
err := p.Properties(ctx, p.Reference(), []string{"name"}, &o)
if err != nil {
return "", err
}
return o.Name, nil
}
func (p ResourcePool) ImportVApp(ctx context.Context, spec types.BaseImportSpec, folder *Folder, host *HostSystem) (*HttpNfcLease, error) {
req := types.ImportVApp{
This: p.Reference(),