By default NettyStreamFactoryFactory creates an NioEventLoopGroup instance and does not close it when the MongoClient closes. We should change the behavior so that it does. We can follow the pattern from TlsChannelStreamFactoryFactory and make it Closeable, and pass it as an externalResourceCloser to the MongoClient implementation.
Since Netty can technically be used even for sync client, this same pattern needs to be applied there as well.