I'm using compute.NewRegionInstanceGroupManagersService's ListManagedInstances call which returns ManagedInstance's.
ManagedInstance has a field Instance which is an instance url, like https://www.googleapis.com/compute/v1/projects/my-project/zones/us-central1-b/instances/instance-group-z0hf
Now I would like to get more details about this particular instance. So using InstanceService's Get call, the function signature looks like this:
func (r *InstancesService) Get(project string, zone string, instance string) *InstancesGetCall
What's the best way to parse the instance URL (see above) into its project, zone and instance parts? Or is there a way of using another method to pass the instance URL directly?