Upstream of any structure means from where the flow of water is coming onto it. And Downstream means to where water is flowing away.
Consider a bridge, The side in which water is coming towards the bridge will be called upstream and the other side will be called downstream.