> setStatus( InstanceStatus.NOT_DEPLOYED )

... and...

> getImports().clear()

... must be applied to all the instances associated with this machine.