Adding ServiceCollection class.
Moved code out of mcp.