Java Forums

Main Menu
Home
Today's Posts
FAQ
Search
Contact Us

Java Network
Java Tips
Java Tips Blog

Sponsored Links





Welcome to the Java Forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community, you will:

  • have access to post topics
  • communicate privately with other members (PM)
  • not see advertisements between posts
  • have the possibility to earn one of our surprises if you are an active member
  • access many other special features that will be introduced later.

Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact us.

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 07-13-2007, 08:50 AM
Member
 
Join Date: Jul 2007
Posts: 5
ganeshsalian is on a distinguished road
Download Tracking
Hi ,

I am downloading some files through Servlet. I want to track whether the download got completed or not through servlet.

Is there any way that i can track the downloads, whether download broke in between because of network issue or if use cancelled the download etc..

Help me out in this regard.

Thanks
Ganesh.
Bookmark Post in Technorati
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 07-13-2007, 10:45 PM
JavaBean's Avatar
Moderator
 
Join Date: May 2007
Posts: 1,272
JavaBean is on a distinguished road
You will need to read data from a thread. This thread will read the file from a port just like you did for a regular file. And while reading it will use a buffer. In this setting, you can count the bytes read and use that information for tracking.

And since you are writing downloading code yourself (as far as i see), you can just catch an exception when a network/IO exception occurs.
Bookmark Post in Technorati
Reply With Quote
  #3 (permalink)  
Old 07-14-2007, 04:23 PM
Member
 
Join Date: Jul 2007
Posts: 5
ganeshsalian is on a distinguished road
Download
Thanks for ur reply.

Presently we are redirecting the download url. No specific download code written.

Do you have any snippet of code which use to download the file.

Thanks,

Ganesh..
Bookmark Post in Technorati
Reply With Quote
  #4 (permalink)  
Old 07-14-2007, 04:42 PM
JavaBean's Avatar
Moderator
 
Join Date: May 2007
Posts: 1,272
JavaBean is on a distinguished road
Hi Ganesh,

I guess this example will help you a lot since all you need is there :

Java Tips - How to create a download manager in Java
Bookmark Post in Technorati
Reply With Quote
  #5 (permalink)  
Old 07-16-2007, 05:46 AM
Member
 
Join Date: Jul 2007
Posts: 5
ganeshsalian is on a distinguished road
Thanks...I will try this out..
Bookmark Post in Technorati
Reply With Quote
  #6 (permalink)  
Old 07-28-2007, 10:28 AM
Member
 
Join Date: Jul 2007
Posts: 5
ganeshsalian is on a distinguished road
Download Tract
We tried the example. Data is getting buffered.

We want to track the download from the Web. We want to track whether user has completed the download process. How can we fullfil our requirement using this. Is there any seperated solution available.

Pls suggest.

Thanks
Bookmark Post in Technorati
Reply With Quote
  #7 (permalink)  
Old 07-28-2007, 08:27 PM
Senior Member
 
Join Date: Dec 2006
Posts: 748
levent is on a distinguished road
I did not understand your problem with the example given. What is missing there? It is a Java code which means you can use it in any Java application/applet including a web application.
Bookmark Post in Technorati
Reply With Quote
  #8 (permalink)  
Old 07-30-2007, 05:57 PM
Member
 
Join Date: Jul 2007
Posts: 5
ganeshsalian is on a distinguished road
Download
Hi,

We have given download option in our site. Normally when user clicks on download, we get save as dialoge box which is browser rendered. When user clicks on save, it is will start downloading, In between if user cancels the operation or if there is any network issue, Here we want to track whether download is been completed or not.

Pls suggest.

Thanks..
Bookmark Post in Technorati
Reply With Quote
Sponsored Links
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
What jdk do I download? padutch2 New To Java 3 11-29-2007 05:28 AM
Tracking Operating System Mansi Networking 2 07-23-2007 02:41 PM
Track download nilesh.malode Advanced Java 1 07-13-2007 10:44 PM
I could download JDK 1.5 Albert New To Java 2 07-13-2007 04:36 PM
Download JDK 1.5 Nick15 New To Java 2 05-27-2007 10:52 AM


All times are GMT +3. The time now is 04:16 AM.


VBulletin, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright ©2006 - 2007, www.java-forums.org