code: func (impl *repoImpl) onInstanceRegistration(c context.Context, inst *model.Instance) error {
  	// Collect IDs of applicable processors.
  	var procs []string
  	for _, p := range impl.procs {
  		if p.Applicable(inst) {
  			procs = append(procs, p.ID())
  		}
  	}
  	if len(procs) == 0 {
  		return nil
  	}
  
  	// Mark the instance as being processed now.
  	inst.ProcessorsPending = procs
  
  	// Launch the TQ task that does the processing (see runProcessorsTask below).
  	return impl.tq.AddTask(c, &tq.Task{
  		Payload: &tasks.RunProcessors{Instance: inst.Proto()},
  		Title:   inst.InstanceID,
  	})
  }
docs: // onInstanceRegistration is called in a txn when registering an instance.