Why might it have been a mistake for Germany to have broken its pact and invaded the Soviet Union during World War II?

Thanks
-MC

Germany then had to fight a prolonged two front war. Their planning was a swift kill of Russia, and that didn't happen.