move trade creation and global update out of transaction