added mutex to the store class to reduce race conditions