...
When using the Horizon 7.5 or above versions with vCenter Server 6.5, the VCCache initialization fails to complete with vCenter Server.In the Horizon View Admin Dashboard, ESXi hosts and Datastores are missing under vSphere Component. Only vCenter Server gets listed.You see stack trace similar to: 2018-07-11T15:03:18.712+02:00 DEBUG (0D84-1970) <VCC-d2d712e2-057f-4251-89ad-305ce0b2402b-1531313834768> [VcCache] Exception from connectAndWait() com.vmware.vdi.logger.Logger.debug(Logger.java:44)java.lang.NullPointerException at com.vmware.vdi.vcsupport25.VmException25.getMethodFault(SourceFile:230) at com.vmware.vdi.vcsupport25.ServiceConnection25.a(SourceFile:1219) at com.vmware.vdi.vcsupport25.ServiceConnection25.waitForUpdatesCancelable(SourceFile:1101) at com.vmware.vdi.vccache.VcCache.f(SourceFile:786) at com.vmware.vdi.vccache.VcCache.run(SourceFile:294) at com.vmware.vdi.vccache.VcCacheInitializer.run(SourceFile:77) at com.vmware.vdi.vccache.VcCacheFederatedTask.run(SourceFile:192) at com.vmware.vdi.common.taskmanager.ExecutorImmediate$a.run(SourceFile:55)2018-07-11T15:03:18.712+02:00 DEBUG (0D84-1970) <VCC-d2d712e2-057f-4251-89ad-305ce0b2402b-1531313834768> [VcCache] Sleeping for 5 seconds before reconnecting In the Connection Server logs, you see these exceptions: javax.xml.ws.soap.SOAPFaultException: Unmarshalling Error: Maximum Element Depth limit (100) Exceeded at org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:161) at com.sun.proxy.$Proxy158.retrieveProperties(Unknown Source) at com.vmware.daas.cloneprep.vcsubsystem.VcSubsystem25.retrieveProperties(VcSubsystem25.java:3602) at com.vmware.daas.cloneprep.vcsubsystem.VcSubsystem25.access$000(VcSubsystem25.java:156) at com.vmware.daas.cloneprep.vcsubsystem.VcSubsystem25$27.invoke(VcSubsystem25.java:3145) at com.vmware.daas.cloneprep.vcsubsystem.VcSubsystem25$27.invoke(VcSubsystem25.java:3142) at com.vmware.daas.cloneprep.vcsubsystem.VcSubsystem25$VcExceptionHandler.invoke(VcSubsystem25.java:3274) at com.vmware.daas.cloneprep.vcsubsystem.VcSubsystem25.callVcMethod(VcSubsystem25.java:1917) at com.vmware.daas.cloneprep.vcsubsystem.VcSubsystem25.initializeCache(VcSubsystem25.java:3142) at com.vmware.daas.cloneprep.cache.CacheManager.populateTempStores(CacheManager.java:768) at com.vmware.daas.cloneprep.cache.CacheManager.populateCache(CacheManager.java:632) at com.vmware.daas.cloneprep.cache.CacheManager.<init>(CacheManager.java:284) at com.vmware.daas.cloneprep.vcsubsystem.VcSubsystem25.<init>(VcSubsystem25.java:277) at com.vmware.daas.cloneprep.vcsubsystem.VcSubsystemFactory.getVcSubsystemNoLock(VcSubsystemFactory.java:302) at com.vmware.daas.cloneprep.vcsubsystem.VcSubsystemFactory.getVcSubsystem(VcSubsystemFactory.java:192) at com.vmware.daas.cloneprep.service.ClonePrepServiceImpl.initialize(ClonePrepServiceImpl.java:123) at com.vmware.vdi.desktopcontroller.VirtualCenterDriver.e(SourceFile:6583) at com.vmware.vdi.desktopcontroller.VirtualCenterDriver.run(SourceFile:7055) at java.lang.Thread.run(Thread.java:748)Caused by: javax.xml.bind.UnmarshalException - with linked exception:[javax.xml.stream.XMLStreamException: Maximum Element Depth limit (100) Exceeded] at com.sun.xml.internal.bind.v2.runtime.unmarshaller.UnmarshallerImpl.handleStreamException(UnmarshallerImpl.java:470) at com.sun.xml.internal.bind.v2.runtime.unmarshaller.UnmarshallerImpl.unmarshal0(UnmarshallerImpl.java:402) at com.sun.xml.internal.bind.v2.runtime.unmarshaller.UnmarshallerImpl.unmarshal(UnmarshallerImpl.java:379) at org.apache.cxf.jaxb.JAXBEncoderDecoder.doUnmarshal(JAXBEncoderDecoder.java:857) at org.apache.cxf.jaxb.JAXBEncoderDecoder.access$100(JAXBEncoderDecoder.java:102) at org.apache.cxf.jaxb.JAXBEncoderDecoder$2.run(JAXBEncoderDecoder.java:896) at java.security.AccessController.doPrivileged(Native Method) at org.apache.cxf.jaxb.JAXBEncoderDecoder.unmarshall(JAXBEncoderDecoder.java:894) at org.apache.cxf.jaxb.JAXBEncoderDecoder.unmarshall(JAXBEncoderDecoder.java:714) at org.apache.cxf.jaxb.io.DataReaderImpl.read(DataReaderImpl.java:179) at org.apache.cxf.wsdl.interceptors.DocLiteralInInterceptor.handleMessage(DocLiteralInInterceptor.java:109) at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:308) at org.apache.cxf.endpoint.ClientImpl.onMessage(ClientImpl.java:835) at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponseInternal(HTTPConduit.java:1684) at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponse(HTTPConduit.java:1560) at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.close(HTTPConduit.java:1361) at org.apache.cxf.transport.AbstractConduit.close(AbstractConduit.java:56) at org.apache.cxf.transport.http.HTTPConduit.close(HTTPConduit.java:658) at org.apache.cxf.interceptor.MessageSenderInterceptor$MessageSenderEndingInterceptor.handleMessage(MessageSenderInterceptor.java:63) at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:308) at org.apache.cxf.endpoint.ClientImpl.doInvoke(ClientImpl.java:535) at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:444) at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:345) at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:298) at org.apache.cxf.frontend.ClientProxy.invokeSync(ClientProxy.java:96) at org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:139) ... 18 moreCaused by: javax.xml.stream.XMLStreamException: Maximum Element Depth limit (100) Exceeded at com.ctc.wstx.sr.InputElementStack.push(InputElementStack.java:329) at com.ctc.wstx.sr.BasicStreamReader.handleStartElem(BasicStreamReader.java:2951) at com.ctc.wstx.sr.BasicStreamReader.nextFromTree(BasicStreamReader.java:2839) at com.ctc.wstx.sr.BasicStreamReader.next(BasicStreamReader.java:1073) at com.sun.xml.internal.bind.v2.runtime.unmarshaller.StAXStreamConnector.bridge(StAXStreamConnector.java:181) at com.sun.xml.internal.bind.v2.runtime.unmarshaller.UnmarshallerImpl.unmarshal0(UnmarshallerImpl.java:400) ... 42 more 2018-07-11T14:59:00.095+02:00 WARN (0D84-197C) <VirtualCenterDriver-d2d712e2-057f-4251-89ad-305ce0b2402b> [VcUtil] Unknown type of SOAPFaultException.Unmarshalling Error: Maximum Element Depth limit (100) Exceeded Will retry. Note: The preceding log excerpts are only examples. Date, time, and environmental variables may vary depending on your environment.
Apache CXF Webservice data parser has a limitation of 100 as MaxElementDepth. When a response from vCenter Server exceeds this range, the data is dropped at the parser level causing exceptions thrown at UI layer.Note: This limitation is for security purpose. For more information, see http://cxf.apache.org/docs/security.html.
To resolve this issue, add the JvmOptions parameter in Tomcat Service of each CS and restart the 'VMware Horizon View Connection Server' service: Go to the following registry path: HKEY_LOCAL_MACHINE\SOFTWARE\VMware, Inc.\VMware VDM\Plugins\wsnm\tomcatService\Params Add this parameter to the JvmOptions. -Dorg.apache.cxf.stax.maxElementDepth=500 Note: Ensure to add a space before -D if you have added at the end of line. No space to be added at the end if it is last parameter in JVmOptions. If the issue persists, increase the value to 1000 or 2000.