All-Star games in sports are always sort of a crux. It's all the best players, competing on the same field.
Both are arguably the best players in their prospective leagues. Both made their name playing for the same team, for long periods of time. Both ultimately left the teams that drafted them for more money