Fixes to routing and composition