code: def _build_cached_instances(self):
          
          connection = self._connect()
          reservations = connection.get_all_reservations()
          cached_instances = {}
          for rs in reservations:
              for vm in rs.instances:
                  cached_instances[vm.id] = vm
          return cached_instances
docs: Build lookup table of VM instances known to the cloud provider.
  
          The returned dictionary links VM id with the actual VM object.