this post was submitted on 26 Jul 2023
26 points (88.2% liked)

Programming

17374 readers
293 users here now

Welcome to the main community in programming.dev! Feel free to post anything relating to programming here!

Cross posting is strongly encouraged in the instance. If you feel your post or another person's post makes sense in another community cross post into it.

Hope you enjoy the instance!

Rules

Rules

  • Follow the programming.dev instance rules
  • Keep content related to programming in some way
  • If you're posting long videos try to add in some form of tldr for those who don't want to watch videos

Wormhole

Follow the wormhole through a path of communities !webdev@programming.dev



founded 1 year ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
[–] deltamaniac@programming.dev 2 points 1 year ago (1 children)

Feature Flags is a concept that helps to enable or disable a feature on an app. Example you would want to roll out a new button on app for a certain set of users, A naive and simplified implementation would look like something below

flags = server.getFlags() // Fetch/Compute feature flags

if (flags.FeatureA == true) {
// show button
}
[–] Deely@programming.dev 5 points 1 year ago (1 children)

Hm, I still not sure about this article lesson.

So, main issue is that users of old version can use new feature, but they should not? On a desktop app? But why they sould not be able to do it in the first place?

I mean idea is good, but situation described in article looks like completely fictitious or incomplete..

[–] ishanpage@programming.dev 5 points 1 year ago (1 children)

The scenario is not ficticious. It's taken straight from my first job, but I had to leave out specific details. The application being developed had something to do with DRM, so that might explain the weird requirements.

The lesson is that sometimes business will require you to force users to update their version, and/or enable specific features for specific subsets of users. So you should have such a mechanism in place before it is required, otherwise you will end up doing hacky things like breaking the server to do what needs to be done.

Systems such as these are actually fairly common in enterprise, but since it was my first job, I had not planned ahead for this because I had no idea.

[–] Deely@programming.dev 2 points 1 year ago

Ah, thanks for explanation, if you implemented DRM/security then it all make sense.