On the other hand, if they write the Java microservices now, running on JDK 11, on Intel x86-64, and then never touch it for 40 years. That will be like some COBOL+mainframe setup that no one knows how to fix, change, upgrade, redeploy, etc.
The tech companies using microservices generally have teams that constantly evolve their products, and over time they end up completely replacing services with new services, underlying infrastructure with new infrastructure, and so on. They will be fine with their Java microservices.
Governments that fund a project once and never touch it again, their technology will always be hard to maintain in 20+ years.