Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Lyo » Connection Timeout error while running StockQuotes sample
Connection Timeout error while running StockQuotes sample [message #1219822] Fri, 06 December 2013 01:26 Go to next message
Shinji Kanai is currently offline Shinji KanaiFriend
Messages: 3
Registered: December 2013
Junior Member
Hello,

Accessing the URL (http://<host>/OSLC4JStockQuote/stockQuotes) results into Http Error 500 due to Connection Timeout. It looks like the problem was caused because Google API to retrieve finance data (line 211 in StockQuoteResource.java) is no longer valid. Does anyone come across the same problem? Can you suggest how to solve it?

Thank you in advance.

--Shinji
Re: Connection Timeout error while running StockQuotes sample [message #1220272 is a reply to message #1219822] Tue, 10 December 2013 18:33 Go to previous messageGo to next message
Samuel Padgett is currently offline Samuel PadgettFriend
Messages: 30
Registered: July 2009
Member
I'm not able to reproduce the error. Are you still seeing the problem? You might also try hitting the service directly to test your connectivity:

http://www.google.com/finance/info?infotype=infoquoteall&q=IBM,Goog

For me this returns stock data in JSON.
Re: Connection Timeout error while running StockQuotes sample [message #1220305 is a reply to message #1220272] Wed, 11 December 2013 00:54 Go to previous messageGo to next message
Shinji Kanai is currently offline Shinji KanaiFriend
Messages: 3
Registered: December 2013
Junior Member
Hello,

Thanks for your reply, but I am still experiencing the issue. The original "uri" string I found is "www.google.com/finance/info?infotype=infoquoteall&q=". Does this uri return anything to you? The link provided by you works for me as well, but the original link returns "nothing" (blank page). Don't you think the original string needs to be updated accordingly?

Best Regards,

--Shinji
Re: Connection Timeout error while running StockQuotes sample [message #1220400 is a reply to message #1220305] Wed, 11 December 2013 14:06 Go to previous messageGo to next message
Samuel Padgett is currently offline Samuel PadgettFriend
Messages: 30
Registered: July 2009
Member
The original string is just the base URL for the service. You need to add a stock symbol after the "q=", which happens later in the code.
Re: Connection Timeout error while running StockQuotes sample [message #1220468 is a reply to message #1220400] Thu, 12 December 2013 00:54 Go to previous message
Shinji Kanai is currently offline Shinji KanaiFriend
Messages: 3
Registered: December 2013
Junior Member
Hi,

Thanks for your assist, your response gave me a hint.
I could resolve the issue by setting "proxy" explicitly in the code:

e.g.
final ClientConfig clientConfig = new ClientConfig();
clientConfig.proxyHost("hostname");
clientConfig.proxyPort(<port>);

Thank you!
Previous Topic:Recommended url paths? Bugzilla example ..?
Next Topic:SecureHelloWorld - consumerStore is null
Goto Forum:
  


Current Time: Tue Mar 19 04:43:28 GMT 2024

Powered by FUDForum. Page generated in 0.02195 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top