> On Aug. 20, 2020, 6:41 a.m., Qian Zhang wrote: > > src/slave/csi_server.cpp > > Line 169 (original), 219 (patched) > > <https://reviews.apache.org/r/72779/diff/3/?file=2238503#file2238503line223> > > > > I'd suggest to rename this `name` local var to something like `_name` > > since we already have a `name` parameter in this method. > > > > And when the `name` parameter is specified, I think we should only > > initialize the plugin of that name rather than initializing all the loaded > > plugins, right? Otherwise a plugin may be intialized multiple times in the > > runtime.
I believe this code should only initialize each plugin once. We initialize all plugins in the `pluginConfigs` map, but if `name` is SOME, then only the plugin with that name will be added to the map. - Greg ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/72779/#review221655 ----------------------------------------------------------- On Aug. 20, 2020, 11:14 p.m., Greg Mann wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/72779/ > ----------------------------------------------------------- > > (Updated Aug. 20, 2020, 11:14 p.m.) > > > Review request for mesos and Qian Zhang. > > > Repository: mesos > > > Description > ------- > > Initialized plugins lazily in the CSI server. > > > Diffs > ----- > > src/slave/csi_server.hpp f5ec7663926731483589c5e30e7060751ed01e55 > src/slave/csi_server.cpp 2ba4f22b92370b019722d845d6113fb37f1b876a > > > Diff: https://reviews.apache.org/r/72779/diff/4/ > > > Testing > ------- > > `sudo bin/mesos-tests.sh --gtest_filter="*CSIServerTest*"` > > > Thanks, > > Greg Mann > >
