Global Middleware, App-Specific Middleware

I see that NC 26 added support for global middlewares. A few questions:

  • Previously, I could use OC\ServerContainer::getRegisteredAppContainer([APP_ID]) and register my middleware directly to a specific app’s container. However, that function returns a DIContainer, which is deprecated in favor of the PSR ContainerInterface. Is it possible to register middleware to a specific application with the new functionality?
  • What apps are included in the “global middleware” registration? Does it include core and settings?