473,396 Members | 1,860 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Different behavior between IIS 5 and internal webserver of VS.Net 2005

Hello,

I don't understand the difference of behavior of these two
webservers :
I'm uploading a file and I launch a thread that makes some treatments
with the Request.Files.
I saw that a new .post file was created on a "upload" directory of the
ASP.Net temporary files.

With the internal webserver :
- When I start my thread, I can use the Request.Files (passed by
parameter) perfectly
With IIS 5 :
- When I start my thread, I can't use the Request.Files (passed by
parameter) because the .post file disappears (just when I enter in my
thread).

So I would want to know why the two webservers have two different
behaviors?
How can I do with IIS 5?

Thanks in advance.
--
David

Jun 25 '07 #1
4 1914
David,
The main difference is the two web servers are completely different
beasts. The test web server that ships with VS is not a great one for heavy
lifting. It was written originally to provide users who have a version of
Windows that doesn't ship with IIS (such as XP Home) an alternative. It is
not based upon the same code and is, I believe, an enhancement of the
Cassini web server that MS released at the ASP.Net web site as a sample way
to integrate the asp.net runtime functionality.

--
Hope this helps,
Mark Fitzpatrick
Former Microsoft FrontPage MVP 199?-2006

<ya**********@gmail.comwrote in message
news:11**********************@q75g2000hsh.googlegr oups.com...
Hello,

I don't understand the difference of behavior of these two
webservers :
I'm uploading a file and I launch a thread that makes some treatments
with the Request.Files.
I saw that a new .post file was created on a "upload" directory of the
ASP.Net temporary files.

With the internal webserver :
- When I start my thread, I can use the Request.Files (passed by
parameter) perfectly
With IIS 5 :
- When I start my thread, I can't use the Request.Files (passed by
parameter) because the .post file disappears (just when I enter in my
thread).

So I would want to know why the two webservers have two different
behaviors?
How can I do with IIS 5?

Thanks in advance.
--
David

Jun 25 '07 #2
Thanks for your response about the difference.
I understand the difference.

I still have my problem with the .post file in the ASP.Net uploads
temporary files that disappears when I enter in my thread.
I tested the same code in .Net 1.1 and I don't have this problem !
The file doesn't disappear and I can read the Request.files (with
saveas method or by using a binaryreader object to read the file, ...)
Otherwise I have an ObjectDisposedException when I check to read it.
I don't know why my file is deleted and by who?
Is it a bad parameter in IIS 5 or in my web.config?
Thanks...
On 25 juin, 16:22, "Mark Fitzpatrick" <markf...@fitzme.comwrote:
David,
The main difference is the two web servers are completely different
beasts. The test web server that ships with VS is not a great one for heavy
lifting. It was written originally to provide users who have a version of
Windows that doesn't ship with IIS (such as XP Home) an alternative. It is
not based upon the same code and is, I believe, an enhancement of the
Cassini web server that MS released at the ASP.Net web site as a sample way
to integrate the asp.net runtime functionality.

--
Hope this helps,
Mark Fitzpatrick
Former Microsoft FrontPage MVP 199?-2006

<yannis.co...@gmail.comwrote in message

news:11**********************@q75g2000hsh.googlegr oups.com...
Hello,
I don't understand the difference of behavior of these two
webservers :
I'm uploading a file and I launch a thread that makes some treatments
with the Request.Files.
I saw that a new .post file was created on a "upload" directory of the
ASP.Net temporary files.
With the internal webserver :
- When I start my thread, I can use the Request.Files (passed by
parameter) perfectly
With IIS 5 :
- When I start my thread, I can't use the Request.Files (passed by
parameter) because the .post file disappears (just when I enter in my
thread).
So I would want to know why the two webservers have two different
behaviors?
How can I do with IIS 5?
Thanks in advance.
--
David- Masquer le texte des messages précédents -

- Afficher le texte des messages précédents -

Jun 25 '07 #3
unless the main page request delays until the background thread
completes, you have a coding error. as soon as the page request
completes, the class is disposed, and the context (which holds the files
collection) is returned to the pool. the next request will reset the
files collection.

your main thread should clone the files collection (and any other
request values required) before passing to the thread.

-- bruce (sqlwork.com)

ya**********@gmail.com wrote:
Hello,

I don't understand the difference of behavior of these two
webservers :
I'm uploading a file and I launch a thread that makes some treatments
with the Request.Files.
I saw that a new .post file was created on a "upload" directory of the
ASP.Net temporary files.

With the internal webserver :
- When I start my thread, I can use the Request.Files (passed by
parameter) perfectly
With IIS 5 :
- When I start my thread, I can't use the Request.Files (passed by
parameter) because the .post file disappears (just when I enter in my
thread).

So I would want to know why the two webservers have two different
behaviors?
How can I do with IIS 5?

Thanks in advance.
--
David
Jun 25 '07 #4
Ok, to clone the files.

I try to use this code sample in my webform (just before calling my
thread) :
Array MyArray = Array.CreateInstance(typeof(String),
Request.Files.Count);
Request.Files.CopyTo(MyArray, 0);

The problem is that I have an exception on the CopyTo method
(ArrayTypeMismatchException).
How can I clone my files before calling the thread?

Thanks...
On 25 juin, 17:17, bruce barker <nos...@nospam.comwrote:
unless the main page request delays until the background thread
completes, you have a coding error. as soon as the page request
completes, the class is disposed, and the context (which holds the files
collection) is returned to the pool. the next request will reset the
files collection.

your main thread should clone the files collection (and any other
request values required) before passing to the thread.

-- bruce (sqlwork.com)

yannis.co...@gmail.com wrote:
Hello,
I don't understand the difference of behavior of these two
webservers :
I'm uploading a file and I launch a thread that makes some treatments
with the Request.Files.
I saw that a new .post file was created on a "upload" directory of the
ASP.Net temporary files.
With the internal webserver :
- When I start my thread, I can use the Request.Files (passed by
parameter) perfectly
With IIS 5 :
- When I start my thread, I can't use the Request.Files (passed by
parameter) because the .post file disappears (just when I enter in my
thread).
So I would want to know why the two webservers have two different
behaviors?
How can I do with IIS 5?
Thanks in advance.
--
David- Masquer le texte des messages précédents -

- Afficher le texte des messages précédents -

Jun 25 '07 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Patrick Masson | last post by:
Hello, Our configuration : Apache 2.0.53 PHP 5.0.4 PC Windows 2000 MATLAB 6.1 We work on a consulting project in France which involves MATLAB Web server,
8
by: TTroy | last post by:
I have a few questions about "scope" and "visibility," which seem like two different things. To me "visibility" of the name of a function or object is the actual code that can use it in an...
9
by: RalphTheExpert | last post by:
I'm getting different behavior if my code is running under the debugger or not. I have modified Winmain to look like this: // Copyright (C) 2002 Microsoft Corporation // All rights reserved....
1
by: William F. Robertson, Jr. | last post by:
I am having problems with using the WebRequest object (or HttpWebRequest ). I have created the WebRequest and set the credentials, but when I call GetResponse() it is throwing an internal server...
9
by: CMan | last post by:
Hi , We have a internal database application which we now need to update from a website hosted at an external site. We want users to be able to come to the website and see their very latest...
7
by: Spsk | last post by:
How to run EXE in webserver on different user credential other than ASPNET. I'm trying to execute EXE in webserver and its runns under ASPNET NT account but I want to run the EXE in different...
12
by: Ann Marinas | last post by:
Hi all, I would like to ask for some help regarding separating the asp.net webserver and the sql server. I have created an asp.net application for a certain company. Initially, we installed...
2
by: mike_li | last post by:
On Window 2000 Professional Server DB2 UDB Level: DB2 code release "SQL07029" with level identifie "030A0105" and informational tokens "DB2 v7.1.0.98", "n040510" and "WR21337". In the...
2
by: Spam Catcher | last post by:
Hi all, I have a webservice which is throwing a 500 Internal Server Error. It seems to be related to the signature of function (or one of the properties within the function). The web service...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.