docs: def get_vpc_overview(con, vpc_id, region_name):
      """
      Retrieve information for the specified VPC.
  
      If no VPC ID was specified then just pick the first VPC we find.
  
      Returns a dict with the VPC's zones, subnets, route tables and
      instances.
  
      """
      logging.debug("Retrieving information for VPC '%s'" % vpc_id)
      d = {}
      d['zones'] = con.get_all_zones()
  
      # Find the specified VPC, or just use the first one
      all_vpcs    = con.get_all_vpcs()
      if not all_vpcs:
          raise VpcRouteSetError("Cannot find any VPCs.")
  
      if not vpc_id:
          # Just grab the first available VPC and use it, if no VPC specified
          vpc = all_vpcs[0]
          vpc_id = vpc.id
      else:
          # Search through the list of VPCs for the one with the specified ID
          vpc = None
          for v in all_vpcs:
              if v.id == vpc_id:
                  vpc = v
                  break
          if not vpc:
              raise VpcRouteSetError("Cannot find specified VPC '%s' "
                                     "in region '%s'." % (vpc_id, region_name))
      d['vpc'] = vpc
  
      vpc_filter = {"vpc-id" : vpc_id}  # Will use this filter expression a lot
  
      # Now find the subnets, route tables and instances within this VPC
      d['subnets']      = con.get_all_subnets(filters=vpc_filter)
      d['route_tables'] = con.get_all_route_tables(filters=vpc_filter)
  
      # Route tables are associated with subnets. Maintain a lookup table from
      # RT ID to (list of) subnets. This is necessary later on, because
      # we only want to set a route in an RT if at least one of the ENIs we are
      # dealing with is associated with the RT. That way, we don't have to set
      # the route in all tables all the time.
      d['rt_subnet_lookup'] = {}
      for rt in d['route_tables']:
          for assoc in rt.associations:
              if hasattr(assoc, 'subnet_id'):
                  subnet_id = assoc.subnet_id
                  if subnet_id:
                      d['rt_subnet_lookup'].setdefault(rt.id, []). \
                                                              append(subnet_id)
  
      # Get all the cluster instances (all EC2 instances associated with this
      # VPC).
      reservations   = con.get_all_reservations(filters=vpc_filter)
      d['instances'] = []
      for r in reservations:  # a reservation may have multiple instances
          d['instances'].extend(r.instances)
  
      # Add reverse lookup from the instances private IP addresses to the
      # subnets they are associated with. More info in the doc for that function.
      _make_ip_subnet_lookup(d)
  
      # Maintain a quick instance lookup for convenience
      d['instance_by_id'] = {}
      for i in d['instances']:
          d['instance_by_id'][i.id] = i
  
      return d