In the old (analogue) days, these were related issues. The way you shifted pitch was by speeding up or slowing down the tape; fixing speed (e.g. Beats per Minute) involved changing pitch. Perhaps the most famous example of this is in the middle of Strawberry Fields where George Martin and Geoff Emerick were asked by John Lennon to splice together takes in different keys and tempos—which they did by speeding up the slower version (in A) and slowing down the faster one (in B) and hoping nobody noticed the slight jump.
Nowadays, of course, they can be independent (but don’t have to be). You can adjust pitch while maintaining speed, and adjust speed while maintaining pitch.