I’ve heard it explained that “hey” used to be more of an urgent way to get someone’s attention, rather than a casual “hello” like it is now, so it sounded rude to some older folks.
If you are a service worker at a restaurant, then that is literally your job, to serve.
I love it when I order a sandwich at my local banh mi place near my office and you can see the cashier literally eye roll every customer that orders. They can’t even look you in the eye…
If you want people to be happy to be serving you then demand that they are paid more.
Otherwise buy your sandwich without any delusions of grandeur and fuck off.