Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/cassandra/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Spring cloud Spring cloud Ribbon Zookeeper中的自定义LoadBlancher规则_Spring Cloud_Spring Cloud Netflix_Netflix Ribbon_Spring Cloud Zookeeper - Fatal编程技术网

Spring cloud Spring cloud Ribbon Zookeeper中的自定义LoadBlancher规则

Spring cloud Spring cloud Ribbon Zookeeper中的自定义LoadBlancher规则,spring-cloud,spring-cloud-netflix,netflix-ribbon,spring-cloud-zookeeper,Spring Cloud,Spring Cloud Netflix,Netflix Ribbon,Spring Cloud Zookeeper,在使用ribbon zookeeper discovery设置自定义负载平衡器规则时遇到问题,当前的规则提供程序是循环的、随机的和粘性的,但是我想要自定义规则。无法对其进行自定义,因此尝试覆盖ZookeeperRibbonClientConfiguration的beandependenciesBasedLoadBalancer,当我尝试覆盖该bean时,出现以下错误 Description: Parameter 1 of method dependenciesBasedLoadBalancer

在使用ribbon zookeeper discovery设置自定义负载平衡器规则时遇到问题,当前的规则提供程序是循环的、随机的和粘性的,但是我想要自定义规则。无法对其进行自定义,因此尝试覆盖
ZookeeperRibbonClientConfiguration
的bean
dependenciesBasedLoadBalancer
,当我尝试覆盖该bean时,出现以下错误

Description:

Parameter 1 of method dependenciesBasedLoadBalancer in io.github.kprasad99.consumer.MasterZookeeperRibbonAutoConfiguration required a bean of type 'com.netflix.loadbalancer.ServerList' that could not be found.


Action:

Consider defining a bean of type 'com.netflix.loadbalancer.ServerList' in your configuration.
Description:

Parameter 0 of method ribbonServerListFromDependencies in io.github.kprasad99.consumer.MasterZookeeperRibbonAutoConfiguration required a bean of type 'com.netflix.client.config.IClientConfig' that could not be found.


Action:

Consider defining a bean of type 'com.netflix.client.config.IClientConfig' in your configuration.
因此,我尝试复制整个文件
ZookeeperRibbonAutoConfiguration
并自定义
depdensciesbaseloadbalancer
,结果出现以下错误

Description:

Parameter 1 of method dependenciesBasedLoadBalancer in io.github.kprasad99.consumer.MasterZookeeperRibbonAutoConfiguration required a bean of type 'com.netflix.loadbalancer.ServerList' that could not be found.


Action:

Consider defining a bean of type 'com.netflix.loadbalancer.ServerList' in your configuration.
Description:

Parameter 0 of method ribbonServerListFromDependencies in io.github.kprasad99.consumer.MasterZookeeperRibbonAutoConfiguration required a bean of type 'com.netflix.client.config.IClientConfig' that could not be found.


Action:

Consider defining a bean of type 'com.netflix.client.config.IClientConfig' in your configuration.
为了解决IClientConfig问题,我尝试从
DefaultClientConfigImpl
创建一个ICleanConfig类型的bean,结果出现了错误

org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'masterSelectorRule' defined in file [kp-service-consumer\target\classes\io\github\kprasad99\consumer\MasterSelectorRule.class]: Unsatisfied dependency expressed through constructor parameter 0; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dependenciesBasedLoadBalancer' defined in class path resource [io/github/kprasad99/consumer/MasterZookeeperRibbonAutoConfiguration.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [com.netflix.loadbalancer.ILoadBalancer]: Factory method 'dependenciesBasedLoadBalancer' threw exception; nested exception is java.lang.RuntimeException: Exception while initializing NIWSDiscoveryLoadBalancer:null, niwsClientConfig:ClientConfig:IgnoreUserTokenInConnectionPoolForSecureClient:null, EnableMarkingServerDownOnReachingFailureLimit:null, DeploymentContextBasedVipAddresses:null, PoolMaxThreads:null, IsSecure:null, ConnectionPoolCleanerTaskEnabled:null, NFLoadBalancerPingInterval:null, NIWSServerListFilterClassName:null, FollowRedirects:null, StaleCheckingEnabled:null, BackoffTimeout:null, MaxAutoRetries:null, ConnectionManagerTimeout:null, NIWSServerListClassName:null, PoolKeepAliveTime:null, CustomSSLSocketFactoryClassName:null, ProxyPort:null, NFLoadBalancerClassName:null, KeyStore:null, Version:null, ForceClientPortConfiguration:null, SecurePort:null, EnablePrimeConnections:null, EnableConnectionPool:null, MaxTotalTimeToPrimeConnections:null, ServerDownFailureLimit:null, Port:null, NFLoadBalancerMaxTotalPingTime:null, ReadTimeout:null, ClientClassName:null, NFLoadBalancerPingClassName:null, MaxRetriesPerServerPrimeConnection:null, RulePredicateClasses:null, EnableGZIPContentEncodingFilter:null, VipAddressResolverClassName:null, ConnIdleEvictTimeMilliSeconds:null, GZipPayload:null, EnableZoneExclusivity:null, KeyStorePassword:null, PrimeConnectionsURI:null, PoolKeepAliveTimeUnits:null, AppName:null, MinPrimeConnectionsRatio:null, RequestIdHeaderName:null, EnableZoneAffinity:null, VipAddress:null, NFLoadBalancerStatsClassName:null, Linger:null, OkToRetryOnAllOperations:null, PrimeConnectionsClassName:null, ConnectionCleanerRepeatInterval:null, TrustStore:null, TrustStorePassword:null, MaxAutoRetriesNextServer:null, listOfServers:null, MaxTotalHttpConnections:null, ReceiveBufferSize:null, ProxyHost:null, ServerDownStatWindowInMillis:null, MaxTotalConnections:null, InitializeNFLoadBalancer:null, PrioritizeVipAddressBasedServers:null, RequestSpecificRetryOn:null, MaxConnectionsPerHost:null, ConnectTimeout:null, UseIPAddrForServer:null, PoolMinThreads:null, ServerListUpdaterClassName:null, SendBufferSize:null, TargetRegion:null, IsClientAuthRequired:null, ServerListRefreshInterval:null, MaxHttpConnectionsPerHost:null, IsHostnameValidationRequired:null, NFLoadBalancerRuleClassName:null
    at org.springframework.beans.factory.support.ConstructorResolver.createArgumentArray(ConstructorResolver.java:769) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.beans.factory.support.ConstructorResolver.autowireConstructor(ConstructorResolver.java:218) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.autowireConstructor(AbstractAutowireCapableBeanFactory.java:1325) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1171) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:555) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:515) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:320) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:318) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:199) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:849) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:877) ~[spring-context-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:549) ~[spring-context-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.boot.web.reactive.context.ReactiveWebServerApplicationContext.refresh(ReactiveWebServerApplicationContext.java:67) ~[spring-boot-2.1.3.RELEASE.jar:2.1.3.RELEASE]
    at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:775) [spring-boot-2.1.3.RELEASE.jar:2.1.3.RELEASE]
    at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:397) [spring-boot-2.1.3.RELEASE.jar:2.1.3.RELEASE]
    at org.springframework.boot.SpringApplication.run(SpringApplication.java:316) [spring-boot-2.1.3.RELEASE.jar:2.1.3.RELEASE]
    at org.springframework.boot.SpringApplication.run(SpringApplication.java:1260) [spring-boot-2.1.3.RELEASE.jar:2.1.3.RELEASE]
    at org.springframework.boot.SpringApplication.run(SpringApplication.java:1248) [spring-boot-2.1.3.RELEASE.jar:2.1.3.RELEASE]
    at io.github.kprasad99.consumer.KpServiceConsumerApplication.main(KpServiceConsumerApplication.java:13) [classes/:na]
Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dependenciesBasedLoadBalancer' defined in class path resource [io/github/kprasad99/consumer/MasterZookeeperRibbonAutoConfiguration.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [com.netflix.loadbalancer.ILoadBalancer]: Factory method 'dependenciesBasedLoadBalancer' threw exception; nested exception is java.lang.RuntimeException: Exception while initializing NIWSDiscoveryLoadBalancer:null, niwsClientConfig:ClientConfig:IgnoreUserTokenInConnectionPoolForSecureClient:null, EnableMarkingServerDownOnReachingFailureLimit:null, DeploymentContextBasedVipAddresses:null, PoolMaxThreads:null, IsSecure:null, ConnectionPoolCleanerTaskEnabled:null, NFLoadBalancerPingInterval:null, NIWSServerListFilterClassName:null, FollowRedirects:null, StaleCheckingEnabled:null, BackoffTimeout:null, MaxAutoRetries:null, ConnectionManagerTimeout:null, NIWSServerListClassName:null, PoolKeepAliveTime:null, CustomSSLSocketFactoryClassName:null, ProxyPort:null, NFLoadBalancerClassName:null, KeyStore:null, Version:null, ForceClientPortConfiguration:null, SecurePort:null, EnablePrimeConnections:null, EnableConnectionPool:null, MaxTotalTimeToPrimeConnections:null, ServerDownFailureLimit:null, Port:null, NFLoadBalancerMaxTotalPingTime:null, ReadTimeout:null, ClientClassName:null, NFLoadBalancerPingClassName:null, MaxRetriesPerServerPrimeConnection:null, RulePredicateClasses:null, EnableGZIPContentEncodingFilter:null, VipAddressResolverClassName:null, ConnIdleEvictTimeMilliSeconds:null, GZipPayload:null, EnableZoneExclusivity:null, KeyStorePassword:null, PrimeConnectionsURI:null, PoolKeepAliveTimeUnits:null, AppName:null, MinPrimeConnectionsRatio:null, RequestIdHeaderName:null, EnableZoneAffinity:null, VipAddress:null, NFLoadBalancerStatsClassName:null, Linger:null, OkToRetryOnAllOperations:null, PrimeConnectionsClassName:null, ConnectionCleanerRepeatInterval:null, TrustStore:null, TrustStorePassword:null, MaxAutoRetriesNextServer:null, listOfServers:null, MaxTotalHttpConnections:null, ReceiveBufferSize:null, ProxyHost:null, ServerDownStatWindowInMillis:null, MaxTotalConnections:null, InitializeNFLoadBalancer:null, PrioritizeVipAddressBasedServers:null, RequestSpecificRetryOn:null, MaxConnectionsPerHost:null, ConnectTimeout:null, UseIPAddrForServer:null, PoolMinThreads:null, ServerListUpdaterClassName:null, SendBufferSize:null, TargetRegion:null, IsClientAuthRequired:null, ServerListRefreshInterval:null, MaxHttpConnectionsPerHost:null, IsHostnameValidationRequired:null, NFLoadBalancerRuleClassName:null
    at org.springframework.beans.factory.support.ConstructorResolver.instantiate(ConstructorResolver.java:627) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:607) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:1305) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1144) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:555) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:515) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:320) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:318) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:199) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.beans.factory.config.DependencyDescriptor.resolveCandidate(DependencyDescriptor.java:277) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.beans.factory.support.DefaultListableBeanFactory.doResolveDependency(DefaultListableBeanFactory.java:1247) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveDependency(DefaultListableBeanFactory.java:1167) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.beans.factory.support.ConstructorResolver.resolveAutowiredArgument(ConstructorResolver.java:857) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.beans.factory.support.ConstructorResolver.createArgumentArray(ConstructorResolver.java:760) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    ... 19 common frames omitted
Caused by: org.springframework.beans.BeanInstantiationException: Failed to instantiate [com.netflix.loadbalancer.ILoadBalancer]: Factory method 'dependenciesBasedLoadBalancer' threw exception; nested exception is java.lang.RuntimeException: Exception while initializing NIWSDiscoveryLoadBalancer:null, niwsClientConfig:ClientConfig:IgnoreUserTokenInConnectionPoolForSecureClient:null, EnableMarkingServerDownOnReachingFailureLimit:null, DeploymentContextBasedVipAddresses:null, PoolMaxThreads:null, IsSecure:null, ConnectionPoolCleanerTaskEnabled:null, NFLoadBalancerPingInterval:null, NIWSServerListFilterClassName:null, FollowRedirects:null, StaleCheckingEnabled:null, BackoffTimeout:null, MaxAutoRetries:null, ConnectionManagerTimeout:null, NIWSServerListClassName:null, PoolKeepAliveTime:null, CustomSSLSocketFactoryClassName:null, ProxyPort:null, NFLoadBalancerClassName:null, KeyStore:null, Version:null, ForceClientPortConfiguration:null, SecurePort:null, EnablePrimeConnections:null, EnableConnectionPool:null, MaxTotalTimeToPrimeConnections:null, ServerDownFailureLimit:null, Port:null, NFLoadBalancerMaxTotalPingTime:null, ReadTimeout:null, ClientClassName:null, NFLoadBalancerPingClassName:null, MaxRetriesPerServerPrimeConnection:null, RulePredicateClasses:null, EnableGZIPContentEncodingFilter:null, VipAddressResolverClassName:null, ConnIdleEvictTimeMilliSeconds:null, GZipPayload:null, EnableZoneExclusivity:null, KeyStorePassword:null, PrimeConnectionsURI:null, PoolKeepAliveTimeUnits:null, AppName:null, MinPrimeConnectionsRatio:null, RequestIdHeaderName:null, EnableZoneAffinity:null, VipAddress:null, NFLoadBalancerStatsClassName:null, Linger:null, OkToRetryOnAllOperations:null, PrimeConnectionsClassName:null, ConnectionCleanerRepeatInterval:null, TrustStore:null, TrustStorePassword:null, MaxAutoRetriesNextServer:null, listOfServers:null, MaxTotalHttpConnections:null, ReceiveBufferSize:null, ProxyHost:null, ServerDownStatWindowInMillis:null, MaxTotalConnections:null, InitializeNFLoadBalancer:null, PrioritizeVipAddressBasedServers:null, RequestSpecificRetryOn:null, MaxConnectionsPerHost:null, ConnectTimeout:null, UseIPAddrForServer:null, PoolMinThreads:null, ServerListUpdaterClassName:null, SendBufferSize:null, TargetRegion:null, IsClientAuthRequired:null, ServerListRefreshInterval:null, MaxHttpConnectionsPerHost:null, IsHostnameValidationRequired:null, NFLoadBalancerRuleClassName:null
    at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:185) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.beans.factory.support.ConstructorResolver.instantiate(ConstructorResolver.java:622) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    ... 33 common frames omitted
Caused by: java.lang.RuntimeException: Exception while initializing NIWSDiscoveryLoadBalancer:null, niwsClientConfig:ClientConfig:IgnoreUserTokenInConnectionPoolForSecureClient:null, EnableMarkingServerDownOnReachingFailureLimit:null, DeploymentContextBasedVipAddresses:null, PoolMaxThreads:null, IsSecure:null, ConnectionPoolCleanerTaskEnabled:null, NFLoadBalancerPingInterval:null, NIWSServerListFilterClassName:null, FollowRedirects:null, StaleCheckingEnabled:null, BackoffTimeout:null, MaxAutoRetries:null, ConnectionManagerTimeout:null, NIWSServerListClassName:null, PoolKeepAliveTime:null, CustomSSLSocketFactoryClassName:null, ProxyPort:null, NFLoadBalancerClassName:null, KeyStore:null, Version:null, ForceClientPortConfiguration:null, SecurePort:null, EnablePrimeConnections:null, EnableConnectionPool:null, MaxTotalTimeToPrimeConnections:null, ServerDownFailureLimit:null, Port:null, NFLoadBalancerMaxTotalPingTime:null, ReadTimeout:null, ClientClassName:null, NFLoadBalancerPingClassName:null, MaxRetriesPerServerPrimeConnection:null, RulePredicateClasses:null, EnableGZIPContentEncodingFilter:null, VipAddressResolverClassName:null, ConnIdleEvictTimeMilliSeconds:null, GZipPayload:null, EnableZoneExclusivity:null, KeyStorePassword:null, PrimeConnectionsURI:null, PoolKeepAliveTimeUnits:null, AppName:null, MinPrimeConnectionsRatio:null, RequestIdHeaderName:null, EnableZoneAffinity:null, VipAddress:null, NFLoadBalancerStatsClassName:null, Linger:null, OkToRetryOnAllOperations:null, PrimeConnectionsClassName:null, ConnectionCleanerRepeatInterval:null, TrustStore:null, TrustStorePassword:null, MaxAutoRetriesNextServer:null, listOfServers:null, MaxTotalHttpConnections:null, ReceiveBufferSize:null, ProxyHost:null, ServerDownStatWindowInMillis:null, MaxTotalConnections:null, InitializeNFLoadBalancer:null, PrioritizeVipAddressBasedServers:null, RequestSpecificRetryOn:null, MaxConnectionsPerHost:null, ConnectTimeout:null, UseIPAddrForServer:null, PoolMinThreads:null, ServerListUpdaterClassName:null, SendBufferSize:null, TargetRegion:null, IsClientAuthRequired:null, ServerListRefreshInterval:null, MaxHttpConnectionsPerHost:null, IsHostnameValidationRequired:null, NFLoadBalancerRuleClassName:null
    at com.netflix.loadbalancer.DynamicServerListLoadBalancer.initWithNiwsConfig(DynamicServerListLoadBalancer.java:133) ~[ribbon-loadbalancer-2.3.0.jar:2.3.0]
    at com.netflix.loadbalancer.DynamicServerListLoadBalancer.<init>(DynamicServerListLoadBalancer.java:99) ~[ribbon-loadbalancer-2.3.0.jar:2.3.0]
    at org.springframework.cloud.zookeeper.discovery.dependency.DependenciesBasedLoadBalancer.<init>(DependenciesBasedLoadBalancer.java:50) ~[spring-cloud-zookeeper-discovery-2.1.1.RELEASE.jar:2.1.1.RELEASE]
    at io.github.kprasad99.consumer.MasterZookeeperRibbonAutoConfiguration.dependenciesBasedLoadBalancer(MasterZookeeperRibbonAutoConfiguration.java:71) ~[classes/:na]
    at io.github.kprasad99.consumer.MasterZookeeperRibbonAutoConfiguration$$EnhancerBySpringCGLIB$$48a8583d.CGLIB$dependenciesBasedLoadBalancer$5(<generated>) ~[classes/:na]
    at io.github.kprasad99.consumer.MasterZookeeperRibbonAutoConfiguration$$EnhancerBySpringCGLIB$$48a8583d$$FastClassBySpringCGLIB$$295e7f78.invoke(<generated>) ~[classes/:na]
    at org.springframework.cglib.proxy.MethodProxy.invokeSuper(MethodProxy.java:244) ~[spring-core-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at org.springframework.context.annotation.ConfigurationClassEnhancer$BeanMethodInterceptor.intercept(ConfigurationClassEnhancer.java:363) ~[spring-context-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    at io.github.kprasad99.consumer.MasterZookeeperRibbonAutoConfiguration$$EnhancerBySpringCGLIB$$48a8583d.dependenciesBasedLoadBalancer(<generated>) ~[classes/:na]
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_172]
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_172]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_172]
    at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_172]
    at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:154) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
    ... 34 common frames omitted
Caused by: java.lang.RuntimeException: Error initializing load balancer
    at com.netflix.loadbalancer.BaseLoadBalancer.initWithNiwsConfig(BaseLoadBalancer.java:227) ~[ribbon-loadbalancer-2.3.0.jar:2.3.0]
    at com.netflix.loadbalancer.DynamicServerListLoadBalancer.initWithNiwsConfig(DynamicServerListLoadBalancer.java:105) ~[ribbon-loadbalancer-2.3.0.jar:2.3.0]
    ... 47 common frames omitted
Caused by: java.lang.NullPointerException: null
    at java.lang.Class.forName0(Native Method) ~[na:1.8.0_172]
    at java.lang.Class.forName(Class.java:264) ~[na:1.8.0_172]
    at com.netflix.client.ClientFactory.instantiateInstanceWithClientConfig(ClientFactory.java:202) ~[ribbon-loadbalancer-2.3.0.jar:2.3.0]
    at com.netflix.loadbalancer.BaseLoadBalancer.initWithNiwsConfig(BaseLoadBalancer.java:221) ~[ribbon-loadbalancer-2.3.0.jar:2.3.0]
    ... 48 common frames omitted
org.springframework.beans.factory.UnsatifiedDependencyException:创建名为“masterSelectorRule”的bean时出错,该bean在文件[kp service consumer\target\classes\io\github\kprasad99\consumer\masterSelectorRule.class]中定义:未满足的依赖项通过构造函数参数0表示;嵌套异常为org.springframework.beans.factory.BeanCreationException:创建名为“dependenciesBasedLoadBalancer”的bean时出错,该名称在类路径资源[io/github/kprasad99/consumer/MasterZookeeperRibbonAutoConfiguration.class]中定义:通过工厂方法实例化bean失败;嵌套异常为org.springframework.beans.BeanInstantiationException:未能实例化[com.netflix.loadbalancer.ILoadBalancer]:工厂方法“dependenciesBasedLoadBalancer”引发异常;嵌套异常为java.lang.RuntimeException:NIWSDiscoveryLoadBalancer初始化时异常:null,niwsClientConfig:ClientConfig:IgnoreUserTokenInConnectionPoolForSecureClient:null,EnableMarkingServerDownOnReachingFailureLimit:null,DeploymentContextBasedIPAddresses:null,PoolMaxThreads:null,IsSecure:null,ConnectionPoolCleanerTaskEnabled:null,NFLoadBalancerPingInterval:null,NIWSServerListFilterClassName:null,以下重定向:null,StaleCheckingEnabled:null,BackoffTimeout:null,MaxAutoMetries:null,ConnectionManagerTimeout:null,NIWSServerListClassName:null,PoolKeepAliveTime:null,CustomsSocketFactoryClassName:null,ProxyPort:null,NFLoadBalancerClassName:null,密钥库:null,版本:null,ForceClientPortConfiguration:null,SecurePort:null,EnablePrimeConnections:null,EnableConnectionPool:null,MaxTotalTimeToPrimeConnections:null,ServerDownFailureLimit:null,端口:null,NFLoadBalancerMaxTotalPingTime:null,ReadTimeout:null,ClientClassName:null,NFLoadBalancerPingClassName:null,MaxRetriesPerServerPrimeConnection:null,RulePredicteClasses:null,EnableGZIPContentEncodingFilter:null,VipAddressResolverClassName:null,ConnidleeVictTimeMillimes:null,GZipPayload:null,EnableZoneExclusivity:null,KeyStorePassword:null,PrimeConnectionUri:null,PoolKeepAliveTimeUnits:null,MinPrimeConnectionRatio:null,RequestIdHeaderName:null,EnableZoneAffinity:null,VipAddress:null,NFLoadBalancerStatsClassName:null,Linger:null,OktoretryonalOperations:null,PrimeConnectionClassName:null,ConnectionCleanerRepeatInterval:null,TrustStorePassword:null,MaxAutoRetriesNextServer:null,listOfServers:null,MaxTotalHttpConnections:null,ReceiveBufferSize:null,ProxyHost:null,ServerDownStatWindowInMillis:null,MaxTotalConnections:null,InitializeNFLoadBalancer:null,PrioritizenVipaddressBasedServers:null,RequestSpecificRetryOn:null,MaxConnectionPerHost:null,ConnectTimeout:null,UseIPAddressForServer:null,PoolMinThreads:null,ServerListUpdaterClassName:null,SendBufferSize:null,TargetRegion:null,IsClientAuthRequired:null,ServerListRefreshInterval:null,MaxHttpConnectionsPerHost:null,IsHostnameValidationRequired:null,NFLoadBalancerRuleClassName:null
在org.springframework.beans.factory.support.ConstructorResolver.createArgumentArray(ConstructorResolver.java:769)~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
在org.springframework.beans.factory.support.ConstructorResolver.autowireConstructor(ConstructorResolver.java:218)~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
在org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.autowireConstructor(AbstractAutowireCapableBeanFactory.java:1325)~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
在org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1171)~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
在org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:555)~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
在org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:515)~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
在org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:320)~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
在org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
在org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:318)~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
在org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:199)~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
在org.springframework.beans.factory.support.DefaultListableBeanFactory.PreInstanceSingleton(DefaultListableBeanFactory.java:849)~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]
在org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:877)~[spring-context-5.1.5.RELEASE.jar:5.1.5.RELEASE]
位于org.springframework.context.support.AbstractApplicationo