IDK if the book of journalist Robin Alexander "Die Getriebenen" (the driven ones, meaning top German politicians driven by events) was ever translated to English, but that guy had daily access to the Chancellory and describes the situation to a T.
Merkel built her career on media appeasement and an illusion that Germany is in such good hands that nothing untoward can happen to it. It sort-of worked until 2015, when the outside world could not be kept at bay anymore.
The reason why governments promote immigration is because they want to increase the workforce (and in the case of Portugal, replace all the emigrants from Portugal). As the population is aging, if you want to keep cheap labor you need new arms to work, no matter who pays for the pensions.