[fix] Fix the middleware example by pausing and resuming the request