Community
Participate
Working Groups
Created attachment 207608 [details] source for the failing bundle. Opened on behalf of Durga Tirunagari. Hi Chris, Sorry I was on vacation for the past week. Please find attached bundle as well as the java (stand-alone project). private static final String GOOGLE_SERVICE = "http://maps.googleapis.com/maps/api/elevation/json?locations="; _Durga Hi Chris, Thanks for the prompt reponse. Please find my responses in line. As far as getting your application to communicate with an external API, I'm guessing it's something like a RESTfull http end point, it's just like any other application running on Tomcat. Absolutely yes, we are talking to a Google Elevation API, to retrieve the Elevation of a particular place. I have a standalone java program that connects to Google Elevation API and get's the elevation, this works fine. Now I am trying to use the same code in one of the java services deployed in Virgo. Virgo doesn't affect things this far up the stack. When you say it is timing out, what exactly is. The connection to Google or one of the bundles in your application starting up itself? The bundles start just fine, the time out is in the connection to the Google Elevation API. Debug logs show Connection Time out while getting InputStream. BTW, here is a code snippet, I removed all the try / catch blocks and just show the main parts of the code. // Create an URL object with the URL to the Google Elevation API. URL source = new URL(GOOGLE_SERVICE); URLConnection urlConnection = source.openConnection(); InputStreamReader streamReader = new InputStreamReader(connection.getInputStream()); The above call time's out ( Connection Time Out ) Thanks a bunch for your help!!!. -Durga Tirunagari Hi Chris, We're trying to write an application, that talks to a Google Elevation API. But the application always time's out. Is there a setting or option in Virgo Web Server we need to make to enable this application that is deployed on Virgo web Server to talk to the Google Elevation API ? Thanks much!!! _Durga
We are following up with Durga about HTTP proxy settings.
The solution was to set -Dhttp.proxyHost and -Dhttp.proxyPort as VM arguments under Eclipse or in JAVA_OPTS when launching via the startup script.