Bundle improvements

Here is the toolkit preparatory work for the automatic activity update feature. It cleans up the bundle API in a way that allows us to clean up the bundleregistry too.