Implement pause and resume