It is possible to split goals into two categories. Task orientated and Ego oriented.
Task orientated goals which focus on mastery of skills. Task orientated goals are more likely to encourage learning even if the goal is not achieved.
Ego orientated goals which focus on achievements. These goals tend to reinforce some aspect of self-image. Boosting ego. Ego orientated tasks tend to make people more anxious about failure.
In sport psychology both goal types can be used. With task oriented goals dominating in the off-season when athletes are preparing for competition. While ego oriented goals dominate during the competitive season.
Websites like Strava focus on ego oriented goals. With the aim being to beat the time of your friends or simply of others riding the same segments as you.
Last year I moved away from competing in events like La Marmotte to focus on improving my mountain bike skills. A shift from ego to task based goals. I stopped making every ride about beating the clock. So I could spent more time exploring. I found new routes even on my well ridden ride to work.