Cherry pick configurable constructor commit from master branch of fork.