The Graf Spee was akin to a battle cruiser - near battleship caliber guns but near cruiser degree of armor. He (the Germans used masculine pronouns for their naval ships) was cruising the South Atlantic, commerce raiding when, IIRC, a RN task group of one heavy (8" guns) and 2 light (6" guns) cruisers engaged the Graf Spee. The RN got the worst of the fight, but managed to make some of Graf Spee's fuel oil unusable. The RN fed the Germans inaccurate information, that an RN carrier group had arrived. Meanwhile, Uruguay insisted on Graf Spee leaving Montevideo, as Uruguay was neutral. Thinking his ship and men would be quickly sunk, with many killed, Langsdorff decided to scuttle the Graf Spee to save his crew's lives.
Going hypothetical, while there was no RN carrier group close at hand, at least one was enroute, so Graf Spee's doom was just farther away than Langsdorff thought. He also may not have had enough usable fuel oil to reach a German port (france had not yet surrendered), so one way or another, Langsdorff made the right choice for the sake of his crew. Hitler would have viewed his choice otherwise, of course.