Break dependency of Config on AgentFactory.
More "Sonar" fixes