Glassdoor / planout4j

Java port of Facebook's PlanOut A/B testing system with additional functionality
Other
117 stars 50 forks source link

Planout document #44

Open dangchienhsgs opened 8 years ago

dangchienhsgs commented 8 years ago

At document describe this. nsConf.defineExperiment("default", "itemsToShow = uniformChoice(choices=[5, 10, 20], unit=userid);");

Newest api: public void defineExperiment(final String definition, final Map<String, ?> assign)

But in the newest apis are different. Can you help me showing the new code to define this example experiment ?

alexkamil commented 4 years ago

see https://github.com/Glassdoor/planout4j/pull/51/files String script = "itemsToShow = uniformChoice(choices=[5, 10, 20], unit=userid);"; nsConf.defineExperiment(experimentName, PlanoutDSLCompiler.dsl_to_json(script));