<p>I would like to implement a server-side A/B test on Kubernetes. However I have no idea where to start and what the best strategy is.</p>
<p>I found two ways of doing this, with the nginx <code>split_client</code> method <a href="https://www.nginx.com/blog/performing-a-b-testing-nginx-plus/" rel="nofollow noreferrer">https://www.nginx.com/blog/performing-a-b-testing-nginx-plus/</a></p>
<p>OR with a kubernetes canary deployment: <a href="https://blog.gurock.com/implement-ab-testing-using-kubernetes/" rel="nofollow noreferrer">https://blog.gurock.com/implement-ab-testing-using-kubernetes/</a></p>
<p>Questions:</p>
<ol>
<li><p>Will the services still be able to autoscale with the canary deployment as replicas numbers are defined for the proper A/B split?</p>
</li>
<li><p>Which strategy seems better, is there one I am not aware of?</p>
</li>
<li><p>Do you have resources or examples of an A/B website test on Kubernetes?</p>
</li>
</ol>

Tim M. Schendzielorz
<p>You could implement  this on ingress level.
Fresh versions of <code>ingress-nginx</code> support weight-based canary deployments out of box.<br />
<a href="https://kubernetes.github.io/ingress-nginx/user-guide/nginx-configuration/annotations/#canary" rel="nofollow noreferrer">https://kubernetes.github.io/ingress-nginx/user-guide/nginx-configuration/annotations/#canary</a>.</p>
<p>Good example here.<br />
<a href="https://medium.com/@domi.stoehr/canary-deployments-on-kubernetes-without-service-mesh-425b7e4cc862" rel="nofollow noreferrer">https://medium.com/@domi.stoehr/canary-deployments-on-kubernetes-without-service-mesh-425b7e4cc862</a></p>
