On the other hand, the President of the European Commission is elected not by a popular vote, but by the popularly elected European Parliament. The members of the cabinet (the commissioners) are proposed by the democratic governments of the member states, and the cabinet as a whole is approved or disapproved by the popularly elected parliament. The same parliament can remove the commission.
In short, the Commission is not directly elected, but selected and approved or vetoed by elected officials, and can be removed if it loses the confidence of the democratically elected legislature.
I'm not aware of the situation in Germany, but I can tell you that in the UK they are elected.
First of all, the leader of each party is elected. There's due to be a Conservative leadership election soon due to the resignation of David Cameron, so you can follow the build up to this election if you're interested in how it works.
Secondly, whilst the positions in a cabinet are selected by the leader of the party, the available pool of people that can be part of that cabinet are all voted for democratically. Therefore, if they do a poor job, they can be voted out at the next election.
In contrast, you have no power to vote out Commissioners who do a poor job, and without that you basically have no power over the decisions they make.