trying to dealwith concurrency