As German stocks outpaced broader European indexes in recent years, a big part of the country’s market was left behind. That’s finally changing.