Hacker News new | past | comments | ask | show | jobs | submit login
Starbucks Does Not Use Two-Phase Commit (2004) (eaipatterns.com)
119 points by gejjaxxita on Aug 17, 2013 | hide | past | favorite | 36 comments



The reason why they call your name is because Schultz, inspired by the "bar" in Milan in the early 1980's, wanted people to believe they had a barista friend. Note that "bar" in Italy has roughly the same meaning as "cafe" in the US. In Italy, then and now, most bars have regular customers, and they get to know each other's name.

When I moved to Singapore a few years ago, I started drinking my coffee at a local "Segafredo", and had to teach to the baristas to call me by name whenever I entered. For a few months, they would say "Buongiorno Mr. Simone" to me only. I also had to teach them how to do a proper espresso. They were clueless. (I was a barista in my twenties). One day I hear "Buongiorno Mr. Giovanni", and I immediately knew it was another Italian. He also did the same, had to teach them to call him by name, and how to do a proper espresso. Funny.


The practice doesn't translate well (culturally) everywhere: http://www.bbc.co.uk/news/magazine-17356957


I suspect that's because a lot of Brits (and the commonwealth, certainly here in NZ) don't take well to commercial friendships. We don't want a random barista knowing our name.

However, if we've seen the same barista every day for a year it's different. So the Italian situation is fine, but asking up front and pretending is not.


I make up a different name every time I go into a Starbucks. I could be Marty one day, Siegfried another, and Rupert the next.


Do they usually know how to spell Siegfried?


No, but that adds to the fun of it.


Here's my story, for what it is worth.

I'm an American. I don't normally go into places like Starbucks. I recently went to a "juice bar" and was one of only two customers there. I paid with cash as I always do nowadays because of Visa/MC/etc data-mining. The one and only person behind the counter asked for my name. It really got my hackles up, I involuntarily scowled and I said I pay cash so I won't have to tell you my name. The poor girl said they only ask for names so orders won't get mixed up - which makes sense from a rote point of view, but was ridiculous given that there were only two customers in the entire place.

I guess if I were used to places asking for my name, I would have simply just made one up on the spot and things would have gone smoothly -- although I dislike being 'forced' to lie on a casual basis like that, if I have a choice I simply won't frequent a business that puts me in that position. I haven't been back to that juice bar since, despite it being only a few blocks from my house.

It seems the "marketing types" really don't get me - walmart greeters disturb me, makes me feel bad for them rather than "welcome" by reminding me how much better off I am than the person who has to take such a dreary and unproductive job. Bathroom attendants totally creep me out with pervo vibes rather than make me feel like I'm in a high-class establishment. My gym forces the people at the front-desk to say goodbye when you leave, which makes me feel like I have to choose between being an asshole and ignoring them or being fake and responding to their corporate-enforced fakeness.

I would really like to know what percentages of the population actually likes this stuff versus simply tolerates it or like myself feels put on the spot by it.


Do you honestly believe that by giving your first name when making an order that data mining will ensue?


Who knows? Some little mom-and-pop juice-bar, probably not. Megalocorp like Starbucks with millions to spend on such a project, quite possibly.

After all, birth-date + gender + zip-code is enough uniquely identify 87% of the population - what's the chance that I've inadvertently let slip some information in addition to my name? Maybe gender, plus first name plus zip-code of the point-of-purchase is similarly revealing? The thing about privacy is once you've lost control of it, you can never get that control back so staying vigilant is important.

http://www.forbes.com/sites/adamtanner/2013/07/22/how-just-a...


Nice story, but my Starbucks barista often gets my name wrong. If being friendly was their intention, rather than matching orders and drinks, they certainly haven't gotten the memo.


What's the error rate, though? For those of us who either find it awkward or just plain incorrect, how many Emily and Johns are there feeling happy that they had a touch of "personal" service?

With an accent, and a short name, giving my name is the part of ordering at Starbucks that I dislike the most, though (presumably due to iterating on the delivery on my part) the retries have become fewer of late. It's especially weird since I pay with the mobile app. No reason my name couldn't be on-screen there for me to point to; some of the smoothest ordering experiences have been while wearing a conference badge, and the cashier wrote my name without asking.

On the other hand, I don't hang out at a specific Starbucks location daily, but I have seen folks who apparently do, and who the staff genuinely do know by name. When my local coffee shop (Red Rock) took my drink order without asking my name I definitely felt pretty special.

Of course, none of this ruins the twinge of embarrassment (is it embarrassment? I'm not sure) I feel whenever a barista loudly yells "LATTE FOR JEN" over the din of an espresso machine.


I give a different name. My problem isn't so much that no one knows how to say mine; it's that no one knows how to spell it, and since someone else reads it, they generally fumble the totally weird series of letters the other barista wrote down. So I started to think of it as less about providing my name -- I don't care about fake familiarity -- and more about providing a uniquish identifier. So I optimize for that: pick a name that everyone knows but few people have. "Art" works pretty well.


Not Ford Prefect? ;-) (I suppose Art Dent is close enough...)


My name is Simone. Try to guess how often my name is pronounced in the wrong way. (hint: it's probably more than 99%). :)


Often wildly wrong.


Fun article, but the title is a little misleading. It's not that Starbucks doesn't use 2-phase commit. It's that they break their sales process into a couple of atomic transactions that run in parallel: payment and delivery. Each of those steps still in fact uses 2-phase commit.

Running a credit card or accepting cash is 2-phase commit. Drink pickup could be seen as a 2-phase commit (put drink on counter, confirm name, take back if name doesn't match). What's interesting is the exception handling logic between these parallel transactions. I.e. if payment fails while drink is getting made, try to cancel the drink delivery.

So the issue here is not "atomic or nonatomic", it's "how do I break a business process down into a set of atomic transactions". Very few businesses are going to run their entire supplier-to-customer process inside of a single atomic transaction.


One additional concept that Starbucks handles is name collisions. If there are two Mikes, the person then must check the type of drink in order to differentiate his order from the other Mike's order. If they happen to be the same, it goes to the first person who ordered (or if one Mike is not aware of the other Mike, it's first come, first serve).


In practice, most people hear "Mike, your Grande Triple-Shot Vanilla Latte is ready!" and immediately someone picks up the drink, studies it, and asks "Is the a Caramel Frappuccino for Dan? I don't see the Whipped Cream!"

I don't know what the programming equivalent is.


Optimistically fuzzy matching?


This is exactly why I use the name "Edgar"


Server is too slow to respond -> hit reload?


Being a Mike, this is why I use the name Titus in many situations. Rarely will there be a name collision. I enjoy seeing the receipts with my name spelled as "Tidas" as well. What's even stranger is when I hand my debit card over, my name as "Michael" is right there, but they don't even question it.


Probably worth a (2004) tag.


And the links to the preceding discussions:

https://www.hnsearch.com/search#request/all&q=starbucks+two+...


Done. Cheers!


I was in Japan last March and one of the souvenirs I brought back was a Starbucks cup holder with my name written on it in Japanese. Granted, it was at a rest stop Starbucks, and I don't recall if they actually called my name out, but perhaps things have changed since 2004 or they treat tourists differently.


If I have no choice but to get my coffee at a Starbucks, I will always order a "brewed coffee". The order is filled by the order-taker and therefore not subject to any of this barrista bullshit..


One thing the article doesn't point out is that, in Japan, coffee shops don't usually take your name during your order.

This means that the customer must listen for the name of their drink instead of their name. Also, when two people order the exact same drink, it can be ambiguous who gets the first served drink.


> In the US, most Starbucks use an explicit correlation identifier by writing your name on the cup and calling it out when the drink is complete. In other countries, you have to correlate by the type of drink.


In my Starbucks, they keep the drinks in a FIFO stack. My drink might be done, but they wait until the other drinks in the queue are delivered before they call mine.

This is okay most of the time, but it is annoying when the person in front of me has a large drink order and I can see my drink ready.


That sounds like my Starbucks. I was sitting at a table and overheard a customer complaining that they got their coffee after someone that ordered after them. After the customer left, I heard the Starbucks manager explain to the new hire that the "queue" is very important. It thought "wow, this sounds like my old Data Structures class!"


LIFO is a stack, FIFO is a queue =)


This topic was explored further in a recent article [1].

http://www.phdcomics.com/comics/archive.php?comicid=1618

[1] Cham, J. G., Slackenerny, M. A. and Smith, B. S. Coffee Security: A need-based analysis for infering bio-related buzz-concepts. Intl. J. Temporal Deflective Behavior 4(1618), pp. 396, 2013.


The article does mention this, at the end of the correlation paragraph.


In the Philippines, they ask for your name, but also ask for the receipt when you pick up your drink. I assume that's primarily for theft prevention. But it was wonderful to have everyone get your name right on the first try (it's Philip).


The article is actually on mapping Messaging, Conversation Pattern and Asynchronous Processing to a real world example. Everybody keeps talking about coffee :)




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: