code: func (res *Resource) AddProcessor(processor *Processor) {
  	for idx, p := range res.Processors {
  		if p.Name == processor.Name {
  			res.Processors[idx] = processor
  			return
  		}
  	}
  	res.Processors = append(res.Processors, processor)
  }
docs: // AddProcessor add processor to resource, it is used to process data before creating, updating, will rollback the change if it return any error