So here's my current problem is we are trying to implement a way to do AB testing. In my opinion the best way to separate users is probably by ID. Basically I would need to map their ID to a boolean (A or B/true or false).
The main problem I have with this though is I would want a method that can give different combinations for different AB testing scenarios. If I do something simple like convert to an Integer mod 2, it becomes difficult to use a parameter to create different groups (mathematically its difficult to make only some of the 1s go to 0 and vice versa even before the mod operation).
I think this leaves me with using a proper hashing algorithm like SHA1 but I figured I would ask if anyone else has a good way of doing this as well.