Use atomic variables for lock free access
For intensive used trivially copyable variables it's better to use atomic ones. It prevents race in isCanceled
For intensive used trivially copyable variables it's better to use atomic ones. It prevents race in isCanceled