Leverage ShutdownState in SourcesCollection

SourcesCollection uses a `shuttingDown` boolean variable to check
whether the configuration should be reloaded.

Updates to the `shuttingDown` variable are done within a synchronized
block, so ensure only one thread at a time can access it.

Since change Ic672c7df5 introduced the `ShutdownState` singleton
however, that should be used to signal and check the shutdown state
of the plugin.

Note that the `ShutdownState` also properly sets the state in a
thread-safe manner, as an equivalent replacement for the syncrhonized
block.

Change-Id: I1022d46f37a89f94fa70721daccf8436617cdfad
1 file changed