Discovery API improvements, PEP8 issues clean up

Previous discovery API didn't allowed agents to get dependent
resources synchronously, e.g. when discovering some service,
get service's configuration file via FileDiscovery agent and
have it cached so that subsequent discovery of that file would
not produce a new resource.
New API changes how discovery is done: agents now represent a
caching resource factories, so when you ask for particular
resource for the second time, it will return a cached instance.
Resources no more accumulated in the main loop but instead collected
from agents afterwards. This overcomes the fact that some agent
could produce multiple resources while current API allows only one
resource to be returned from agent's discover() method.

Extended file discovery methods: now you can use wildcards to collect
multiple files at once and use search paths (e.g. when you want to
search for config file in several directories and collect whichever
found first).

Cleaned up PEP8 issues regarding unused imports and 'import *'.

Added CLI options for discovery_test to output JSON and choose log
level.

IssueReporter subclasses now won't contain duplicate entries.

Change-Id: I7371ccce1e2f3c0a649fe9d6a41b146f04c0f4c1