how to deal with upstream