javax.xml.stream.XMLStreamException while validating xml

javax.xml.stream.XMLStreamException: ParseError at [row,col]:[2,134]
Message: Tried all: ‘1’ addresses, but could not connect over HTTP to server: ‘java.sun.com’, port: ’80’

at com.sun.xml.stream.XMLReaderImpl.next(XMLReaderImpl.java:545)
at weblogic.servlet.internal.TldCacheHelper$TldIOHelper.parseXML(TldCacheHelper.java:132)
at weblogic.descriptor.DescriptorCache.parseXML(DescriptorCache.java:380)
at weblogic.servlet.internal.TldCacheHelper.parseTagLibraries(TldCacheHelper.java:65)
at weblogic.servlet.internal.War.getTagInfo(War.java:889)
at weblogic.servlet.internal.WebAppServletContext$ServletContextWebAppHelper.getTldInfo(WebAppServletContext.java:3708)

You might encounter the following exception when the server on which Weblogic is hosted is not able to communicate to internet.The reason being that internet access is allowed only via proxy.
To allow access we need to pass on the proxy details as a JVM Option.

-Dhttp.proxyHost= -Dhttp.proxyPort=

This should resolve the issue.

You can test the connection by a simple jsp that makes a URL Connection

System.setProperty(“http.proxyHost”, “proxy host”);
System.setProperty(“http.proxyPort”, “proxy port”);
URL url = new URL(“http://java.sun.com:80”);