It is racist, you're right, and upsetting. If it upsets you, then it's insensitive and wrong. That is the test, for all right-thinking people, of whether something is offensive.
However, the stall holder was probably clumsily struggling for a parallel. He might have picked another one, not focusing on your DH, but on cab rides, for instance or fruit and veg. But he's wrong anyway, as lots of retail does give discounts.
But actually , looking past the comment, the stall holder is wrong, as, if you weren't so shocked at his choice of parallel, you could have pointed out. For instance, if he and his wife and ten family members had gone into any restaurant, they probably might have been offered a free bottle of wine or some free sweets with coffee. People booking catering for parties probably don't pay menu prices, but get a bulk discount. Your partner could have said, ' Yes, but my restaurants have overheads, but you don't have business rates and salaries, mate.' He could have made a joke of the stereotyping, even though you don't work in, or run a restaurant. He could have turned to you and said: 'Get you're apron on, you've got to make those poppadoms for tonight!', and just made a joke of it. ' Or can I swap a free starter for all this tat?'.
It may be some stallholders have been affected by Covid and are feeling a bit bad-tempered and desperate to claw back some income. Or this guy might just have been very unimaginative and very silly.