#java #netflix-zuul #netflix-eureka
#java #netflix-zuul #netflix-эврика
Вопрос:
Я пытаюсь запустить Netflix Zuul (https://github.com/Netflix/zuul ) и Netflix Эврика (https://github.com/Netflix/eureka ) на моем веб-сервере. Zuul может зарегистрироваться в Eureka. Однако, когда Zuul пытается получить список служб, зарегистрированных в Eureka, я получаю следующую ошибку:
`
DiscoveryClient_ZUUL/zuul-01.bm.net - was unable to refresh its cache! status = java.lang.Boolean cannot be cast to java.lang.String :` java.lang.Boolean cannot be cast to java.lang.String
at com.thoughtworks.xstream.core.TreeUnmarshaller.convert(TreeUnmarshaller.java:79)
at com.thoughtworks.xstream.core.TreeUnmarshaller.convertAnother(TreeUnmarshaller.java:66)
at com.thoughtworks.xstream.core.TreeUnmarshaller.convertAnother(TreeUnmarshaller.java:50)
at com.netflix.discovery.converters.Converters$ApplicationConverter.unmarshal(Converters.java:226)
at com.thoughtworks.xstream.core.TreeUnmarshaller.convert(TreeUnmarshaller.java:72)
at com.thoughtworks.xstream.core.TreeUnmarshaller.convertAnother(TreeUnmarshaller.java:66)
at com.thoughtworks.xstream.core.TreeUnmarshaller.convertAnother(TreeUnmarshaller.java:50)
at com.netflix.discovery.converters.Converters$ApplicationsConverter.unmarshal(Converters.java:145)
at com.thoughtworks.xstream.core.TreeUnmarshaller.convert(TreeUnmarshaller.java:72)
at com.thoughtworks.xstream.core.TreeUnmarshaller.convertAnother(TreeUnmarshaller.java:66)
at com.thoughtworks.xstream.core.TreeUnmarshaller.convertAnother(TreeUnmarshaller.java:50)
at com.thoughtworks.xstream.core.TreeUnmarshaller.start(TreeUnmarshaller.java:134)
at com.thoughtworks.xstream.core.AbstractTreeMarshallingStrategy.unmarshal(AbstractTreeMarshallingStrategy.java:32)
at com.thoughtworks.xstream.XStream.unmarshal(XStream.java:1052)
at com.thoughtworks.xstream.XStream.unmarshal(XStream.java:1036)
at com.thoughtworks.xstream.XStream.fromXML(XStream.java:921)
at com.netflix.discovery.converters.EntityBodyConverter.read(EntityBodyConverter.java:61)
at com.netflix.discovery.provider.DiscoveryJerseyProvider.readFrom(DiscoveryJerseyProvider.java:94)
at com.sun.jersey.api.client.ClientResponse.getEntity(ClientResponse.java:634)
at com.sun.jersey.api.client.ClientResponse.getEntity(ClientResponse.java:586)
at com.netflix.discovery.DiscoveryClient.getAndStoreFullRegistry(DiscoveryClient.java:853)
at com.netflix.discovery.DiscoveryClient.fetchRegistry(DiscoveryClient.java:752)
at com.netflix.discovery.DiscoveryClient.access$1400(DiscoveryClient.java:110)
at com.netflix.discovery.DiscoveryClient$CacheRefreshThread.run(DiscoveryClient.java:1778)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
Caused by: java.lang.ClassCastException: java.lang.Boolean cannot be cast to java.lang.String
at org.codehaus.jettison.mapped.MappedNamespaceConvention.processAttributesAndNamespaces(MappedNamespaceConvention.java:119)
at org.codehaus.jettison.Node.<init>(Node.java:55)
at org.codehaus.jettison.mapped.MappedXMLStreamReader.processElement(MappedXMLStreamReader.java:147)
at org.codehaus.jettison.mapped.MappedXMLStreamReader.next(MappedXMLStreamReader.java:77)
at com.thoughtworks.xstream.io.xml.StaxReader.pullNextEvent(StaxReader.java:58)
at com.thoughtworks.xstream.io.xml.AbstractPullReader.readRealEvent(AbstractPullReader.java:148)
at com.thoughtworks.xstream.io.xml.AbstractPullReader.readEvent(AbstractPullReader.java:135)
at com.thoughtworks.xstream.io.xml.AbstractPullReader.hasMoreChildren(AbstractPullReader.java:87)
at com.netflix.discovery.converters.Converters$InstanceInfoConverter.unmarshal(Converters.java:380)
Я пытался отладить это, но не смог найти основную причину этой ошибки.
Комментарии:
1. вы создаете из исходного кода?