Plain rivers in the place I originally from are usually either deep or fast, so to go through a rapid you can dive to the bottom where the stream is slower, then swim some time underwater, usually at some angle. A series of dives was much more efficient compared to surface swimming.
Not OP, but the current is slower in eddies and at the very bottom. If you actually need to get upstream rather than just have fun playing, you can just walk on the bank. ISTM the only absolutely necessary technique for fast streams is the ferry. Speed is definitely helpful for that, although it isn't entirely "swimming against".
Ferrying is crossing a river, by propelling oneself (either swimming or in a boat) diagonally across and against the main current. In e.g. a canoe it's easy to do so without being pushed downstream at all, while when swimming you will lose some ground. The skill is knowing the best angle to take.
"ISTM" is "it seems to me", in any online discussion. b^)