S
Steven Burn
The application;
Service on my webserver that allows a user to upload their HOSTS file for functions to verify the contents are still valid.
Uses;
1. XMLHTTP (MSXML2)
2. FileSystemObject
3. CrazyBeavers Upload control (couldn't get the Dundas one to work)
How it's supposed to work;
1. User uploads file (test file = 1.10MB)
2. FSO saves file to server then prepares for reading
3. File is opened using the Read(n) method (line # 45 in res_upload.txt)
4. Content is parsed and the parts required, passed to a function (URLExists)
5. Status saved to report to later show to client
Files:
Test file: hpHosts - http://www.hosts-file.net
Example report: http://mysteryfcm.plus.com/?mode=Hosts&bFile=2252005_132703_copy of hosts.txt.htm
Code that uploads then processes the file: http://mysteryfcm.plus.com/res_upload.txt
The problem;
The file can contain anything from 10 lines to 20,000+ lines, each one is parsed and passed to the URLExists function. I'm not entirely sure whether the problem is due to the content itself, or the number of calls to the XMLHTTP object but, a file containing 10,000 lines (the test file) times out after around 1,000 lines.
The timeout set for the URLExists function is 5 seconds (the timeout takes well over an hour of reading/parsing, to occur), the script timeout is set to 5000
I've tried cutting alot of the content of the test file out so it's 206K instead of 1.10MB, but it's still taking forever to process, and then timing out anyway.
The question;
I've found some doc's online that show how to read and parse large files with a ton of content and have applied this to the application in question but for reasons best known to itself, it is still timing out. What I'm wondering is;
1. Would it be best to ditch the application server-side and make it a downloadable application instead?
It would be easier to work with in VB but thats the reason I didn't want to do it that way (I like a challenge).
2. Would it be viable to split the file into parts once uploaded, and process each part seperately instead of doing it the way I'm currently doing it?.
3. Is there a better alternative that I've simply not thought of?
I've probably not given enough info and apologies in advance if this is the case (got a million and one things going through my head atm). Thanks in advance for any advice/suggestions.
--
Regards
Steven Burn
Ur I.T. Mate Group
www.it-mate.co.uk
Keeping it FREE!
Service on my webserver that allows a user to upload their HOSTS file for functions to verify the contents are still valid.
Uses;
1. XMLHTTP (MSXML2)
2. FileSystemObject
3. CrazyBeavers Upload control (couldn't get the Dundas one to work)
How it's supposed to work;
1. User uploads file (test file = 1.10MB)
2. FSO saves file to server then prepares for reading
3. File is opened using the Read(n) method (line # 45 in res_upload.txt)
4. Content is parsed and the parts required, passed to a function (URLExists)
5. Status saved to report to later show to client
Files:
Test file: hpHosts - http://www.hosts-file.net
Example report: http://mysteryfcm.plus.com/?mode=Hosts&bFile=2252005_132703_copy of hosts.txt.htm
Code that uploads then processes the file: http://mysteryfcm.plus.com/res_upload.txt
The problem;
The file can contain anything from 10 lines to 20,000+ lines, each one is parsed and passed to the URLExists function. I'm not entirely sure whether the problem is due to the content itself, or the number of calls to the XMLHTTP object but, a file containing 10,000 lines (the test file) times out after around 1,000 lines.
The timeout set for the URLExists function is 5 seconds (the timeout takes well over an hour of reading/parsing, to occur), the script timeout is set to 5000
I've tried cutting alot of the content of the test file out so it's 206K instead of 1.10MB, but it's still taking forever to process, and then timing out anyway.
The question;
I've found some doc's online that show how to read and parse large files with a ton of content and have applied this to the application in question but for reasons best known to itself, it is still timing out. What I'm wondering is;
1. Would it be best to ditch the application server-side and make it a downloadable application instead?
It would be easier to work with in VB but thats the reason I didn't want to do it that way (I like a challenge).
2. Would it be viable to split the file into parts once uploaded, and process each part seperately instead of doing it the way I'm currently doing it?.
3. Is there a better alternative that I've simply not thought of?
I've probably not given enough info and apologies in advance if this is the case (got a million and one things going through my head atm). Thanks in advance for any advice/suggestions.
--
Regards
Steven Burn
Ur I.T. Mate Group
www.it-mate.co.uk
Keeping it FREE!