Modifies stress example to use new API.