functional options experiment
migrate endpoint config to functional interface model http://dave.cheney.net/2014/10/17/functional-options-for-friendly-apis