>source

리본 주 키퍼 검색으로 사용자 지정로드 밸런서 규칙을 설정하는 데 문제가 있지만 현재 규칙 공급자는 ROUND_ROBIN, RANDOM 및 STICKY이지만 사용자 지정 규칙을 원했습니다. 그것을 커스터마이징 할 방법이 없으므로 콩 dependenciesBasedLoadBalancer 를 덮어 썼습니다.  와이즈 비츠 , 콩을 무시하려고 할 때 오류가 발생합니다.

ZookeeperRibbonClientConfiguration

따라서 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. 전체 파일을 복사하려고합니다.  그리고 ZookeeperRibbonAutoConfiguration 를 주문을 받아서 만드십시오 , 아래 오류가 발생했습니다.

depdenciesBaseLoadBalancer

IClientConfig 문제를 해결하기 위해 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. 에서 ICleanConfig 유형의 Bean을 작성하려고했습니다. 이제 오류가 발생했습니다.

DefaultClientConfigImpl

맞춤로드 밸런서 규칙을 추가하는 방법

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
  • 답변 # 1

    아래와 같이 serviceId 및 namesapce를 사용하여 기본값으로 생성 된 기본 생성자로 빈을 생성하는 대신 문제가 해결되었습니다.

     @Bean
        public IClientConfig ribbonClientConfig() {
            return DefaultClientConfigImpl.getClientConfigWithDefaultValues(serviceId, DEFAULT_NAMESPACE);
        }
    
    

관련 자료

  • 이전 javascript - * ngFor 배열의 길이로 서비스에 가입
  • 다음 gdb - 캐스트는 컴파일 된 언어에 따라 다릅니다