XD-1036: Composed module deletion

Keeps track of usage of modules by
 * streams
 * other composed modules

Not sure about naming of classes (could be made more generic and also used to track inter stream deps), but that can be addressed in another PR