Fix discovery client if enabled but no impl available
If user has @EnableDiscoveryClient but no implementation (e.g. if he
just has @EnableZuulProxy) the autoconfig will now kick in and
provide an instance of NoopDiscoveryClient.
Fixes gh-80
@ -51,8 +51,8 @@ public abstract class SpringFactoryImportSelector<T> implements
@@ -51,8 +51,8 @@ public abstract class SpringFactoryImportSelector<T> implements
@ -60,24 +60,24 @@ public abstract class SpringFactoryImportSelector<T> implements
@@ -60,24 +60,24 @@ public abstract class SpringFactoryImportSelector<T> implements
+" found, but there are no implementations. Did you forget to include a starter?");
}
if(factories.size()>1){
// there should only ever be one DiscoveryClient, but there might be more than one factory
// there should only ever be one DiscoveryClient, but there might be more than
// one factory
log.warn("More than one implementation "+"of @"+getSimpleName()
+" (now relying on @Conditionals to pick one): "+factories);
}
@ -85,6 +85,10 @@ public abstract class SpringFactoryImportSelector<T> implements
@@ -85,6 +85,10 @@ public abstract class SpringFactoryImportSelector<T> implements