Solution :
I have read your question which you have posted in this forum. Dealing with Doctrine is very tricky thing. I had also faced the issue in the past. So I am trying to help you in resolving your issue.
I think parameters on a signature of a @Route annotation must be matching with the entities fields, so that the Doctrine makes the automatically conversion.
Or else you will need to do a conversion manually by using a following annotation @ParamConverter.
Your Doctrine will not know how to use your request parameters to query the entities which you have specified in your function's signature.
So you must help it by just specifying some of the mapping information as shown below:
/**
* @Route("/gatheractor /{ actor_name }/{gather_id}")
*
* @ParamConverter("actor", options={"mapping": {" actor_name " : "name"}})
* @ParamConverter("gather", options={"mapping": {"gather_id" : "id"}})
*
* @Template()
*/
public function createActorAction(Actor $actor, Gather $gather)
{
// ...
}