18. The Etsy search backend
Web app
• New algorithm search()
• New RPC protocol searchA() searchB()
• New result data structure
Search Search
• New Solr trunk snapshot cluster A cluster B
Tuesday, July 26, 2011
19. DB re-architecture
• Postgres => Sharded MySQL
• Multiple experiments
Tuesday, July 26, 2011
20. Whole new features
New pages
+
New DB tables
+
New batch jobs
+
...
Tuesday, July 26, 2011
21. Not just 2 variants
• A/B/C... tests
• Multi-variate tests
Tuesday, July 26, 2011
22. Caveats
• Content not under your control
• Price tests?
• Hard-to-measure/quantify things
• Long term impact?
Tuesday, July 26, 2011
23. Other tests
• Internal users testing
• Whitelisted user testing
Tuesday, July 26, 2011
25. Complementary techniques
• Observed/recorded testing
- show different people the same thing
• Side-by-side testing
- show each person 2 alternatives
Tuesday, July 26, 2011
38. Now we go crazy...
function do_new_search() {
// exciting new stuff
// that might or might not work
// but we can deploy it anyway
// since it’s flagged off
}
Tuesday, July 26, 2011
51. Variants
• Key-value pairs
• interpreted by the app
• Name
• mostly for logging
Tuesday, July 26, 2011
52. SubjectIdProvider
function getID()
• Why?
• hashing and other selectors
• logging
• Types of subjects
• Users...but not always
• Different groups of users - sellers vs buyers, etc.
• Different ways to identify them - signed in vs signed out
Tuesday, July 26, 2011
53. Selectors
function select($subjectID) => Variant Name
Tuesday, July 26, 2011
54. Combining multiple selectors
• OR
• breaks blacklists
• AND
• breaks whitelists
• Sequence
• works!
Tuesday, July 26, 2011
55. Selector sequence
• Defines an ordering
• Returns A/B/C/... or <don't care>
Tuesday, July 26, 2011
56. Loggers
function log($testKey, $variantKey, $subjectKey)
Tuesday, July 26, 2011
57. More => better
• More data
• More ways to track
• access logs
• 3P analytics
• custom
Tuesday, July 26, 2011
65. Test builders
• Capture common patterns
• feature ramp ups
• opt-in experiments
• Help with test design
• weight equalization
• multivariate testing
Tuesday, July 26, 2011
66. Automatic Dispatchers
• Separate dispatching and work
• Work with components that have well-defined
invocation APIs
• Define a particular level of granularity
• Feel like magic
Tuesday, July 26, 2011
67. Dispatcher example - MVC
• View dispatch
• Controller dispatch
• Spring framework, etc.
Tuesday, July 26, 2011
75. Persistence
• Better experience
Tuesday, July 26, 2011
76. Persistence
• Better experience
• Better data
Tuesday, July 26, 2011
77. Persistence
• Better experience
• Better data
• Multi-part tests
Tuesday, July 26, 2011
78. Persistence
• Better experience
• Better data
• Multi-part tests
• ...but not forever
Tuesday, July 26, 2011
79. Ramping up/down
• Vary group sizes
• Reduce risk
• Distribute load
Tuesday, July 26, 2011
80. Persistence + Ramping
• Minimize inconsistency
• Ramping up
• Should just add people to the treatment group
• Ramping down
• Should just remove part of the treatment group
Tuesday, July 26, 2011
81. rand()
• Explicit persistence
• Cookie
• DB
• Scaling
• Maintenance
Tuesday, July 26, 2011
82. Hashing
variant = H(id)
Tuesday, July 26, 2011
83. Hashing
variant = H(id)
Persistence
Tuesday, July 26, 2011
84. Hashing
variant = H(id)
Persistence
Tuesday, July 26, 2011
96. Partitioning
Hash
0 A B 1
.5
Partition
Tuesday, July 26, 2011
97. Ramping up
Hash
0 A B 1
.7
Partition
Tuesday, July 26, 2011
98. Which hash function?
• MD5/SHA-256/...
• Test it!
• But be careful...
Tuesday, July 26, 2011
99. A/B + opt-in
• Need to separate the groups for analysis
• Solution: use more than 2 variants!
• Act according to variant properties
• Track by variant name
Tuesday, July 26, 2011
112. Who?
• Different roles
• Old vs new
• Novelty
• Habit
• Expectation
Tuesday, July 26, 2011
113. When?
• User types vary
• Activity patterns vary
• Site content might vary
• Performance might vary
• Full weeks are often a good starting point
Tuesday, July 26, 2011