Keg-Beverage Relationship

I’m not sure that I understand the relationship between Keg and Beverage. When creating a keg, it also creates an associated beverage. The characteristics of the Beverage can be updated, but the Keg is locked to a particular Beverage and Producer. This really doesn’t make sense from a homebrew perspective as I have a finite number of kegs (5) in which I fill with different Beverage(s) each time. It’s not clear why a Keg isn’t just KEGx and then I can add/change the current Beverage associated with a particular keg. I would appreciate an explanation of how I should be thinking about the Keg/Beverage relationship. Thanks!

It’s a great question. A good way to think about a “keg” is that it is basically a one-time composition of a beverage and a shell. Once a keg is kicked, it’s only meaning in the system is as a sort of historical record of that beverage (and volume) having been served. “We served 23 kegs this month” is great for the average bar’s analytic needs; who knows where the sheet metal went.

Another way to put it is that shells aren’t tracked as a discrete entity anywhere. Your use case makes sense for homebrewers. For most bars, restaurants, and other kinds of hobby users, shells are less interesting - they’re just going to be picked up and replenished.

I do think there’s room to evolve this, but it would take care not to complicate the more common case & preserve simplicity: Basically if you don’t care about the shells, you shouldn’t have to.

Hope that makes sense!

Thank you. This explanation helps reconcile this in my mind. However, what doesn’t make sense is why can’t the Beverage [relationship] and Producer for a Keg be edited since the keg is referenced by ID number anyway?

That could be possible: Kegs “point to” a beverage, it’s just that this use case wasn’t built into the UI. Although, I believe the under-the-hood, coming-soon rest API may allow it. In any case, the data model allows it. I’ll definitely add it as a feature request; tho doing it right would probably quickly require supporting empty (beverage-free) kegs, which starts to break bigger assumptions under the hood.

it seems like its set up so that you can have a keg that’s a a single recipe that you do, but you can edit a single keg of it to make that display differently. I do an IPA fairly regularly, but I brewed one batch that my brew buddy and I doubled up the hops on - so the hop bomb got its own keg with separate description. I guess if you never brew the same thing twice it doesn’t help you much though.