src/bosh-softlayer-cpi/softlayer/client/client.go
func (c *ClientManager) CreateSnapshot(volumeId int, notes string) (datatypes.Network_Storage, error) {
	for {
		networkStorage, err := c.StorageService.Id(volumeId).CreateSnapshot(sl.String((notes)))
		if err != nil {
			apiErr := err.(sl.Error)
			if apiErr.Exception == SOFTLAYER_PUBLIC_EXCEPTION &&
				strings.Contains(apiErr.Message, "please try again after Volume Provisioning is complete") {
				continue
			}

			return datatypes.Network_Storage{}, err
		}

		return networkStorage, nil
	}
}
func (c *ClientManager) CreateSnapshot(volumeId int, notes string) (datatypes.Network_Storage, error) {
	for {
		networkStorage, err := c.StorageService.Id(volumeId).CreateSnapshot(sl.String((notes)))
		if err != nil {
			apiErr := err.(sl.Error)
			if apiErr.Exception == SOFTLAYER_PUBLIC_EXCEPTION &&
				strings.Contains(apiErr.Message, "please try again after Volume Provisioning is complete") {
				continue
			}

			return datatypes.Network_Storage{}, err
		}

		return networkStorage, nil
	}
}
// Creates a snapshot on the given block volume.
// volumeId: The id of the volume
// notes: The notes or "name" to assign the snapshot