File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Sockets and Internet Protocols and the fly likes URLFetchServiceFactory? Asynchronous http request?? Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Java » Sockets and Internet Protocols
Reply Bookmark "URLFetchServiceFactory? Asynchronous http request??" Watch "URLFetchServiceFactory? Asynchronous http request??" New topic
Author

URLFetchServiceFactory? Asynchronous http request??

sin kang
Greenhorn

Joined: Sep 24, 2010
Posts: 1
Hi all,

I need to implement a class like the one available in the com.google.appengine.api.urlfetch.URLFetchServiceFactory package.

I also need to implement a class to make asynchronous http request.

I was trying to get some ideas how to implement and all by searching the source code of those classes. Somehow, I coud not find ones.

Can you guys help me out on this? say How I should implement?? or any ideas?? or sample codes I can look up into??

Thanks guys.
Ernest Friedman-Hill
author and iconoclast
Marshal

Joined: Jul 08, 2003
Posts: 24054
    
  13

Hi,

Welcome to JavaRanch!

I'd think this would be rather simple: you'd just implement a synchronous fetch from a URL, but do it in a separate thread. Your API could provide a callback method so that when the fetch is complete, the callback could be notified.


[Jess in Action][AskingGoodQuestions]
 
I agree. Here's the link: http://zeroturnaround.com/jrebel - it saves me about five hours per week
 
subject: URLFetchServiceFactory? Asynchronous http request??
 
Similar Threads
Configuring a Startup class
Getting IP and location of a client
Appropiate way to Update the cache
how to maintain reference to the response object
how to maintain reference to the response object