Performance implications of batch = false install? WCF service recompiles even if batch mode

I have a wcf service hosted on my website (Windows Server 2003 with iis 6, Dot Net Framework 4.0).

When I deploy this service, it starts on the production server. But after a day this service stops and I get an error:

The service could not be activated due to an exception during compilation. Exception message. Could not load file or assembly App_web_jm4, Version = 0.0.0.0. The system cannot find the file specified.

To fix this problem I had to do iis reboot (very bad solution), but still I got this error the next day.

I read somewhere that changing this web.Config tag solves the problem:

<compilation targetFramework="4.0"  batch="false">

      

This actually solved my problem.

But I want to know:

1) Are there any implications for the above solution for my site, because the documentation does not say the impact when the value of this batch parameter is false.

2) Are there any other solutions?

These solutions didn't work for me.

EDIT: Since it is classified as a duplicate web.config batch = "false" :

Here's what I understood from this post:

Batch mode = true -> The compiler compiles all files separately the first time and the subsequent request comes from there.

Batch mode = false -> The compiler compiles all files together.

This means I am subject to a performance penalty and not a good solution to my problem.

But about the second part:

The documentation states

When this attribute is set to True, ASP.NET will pre-compile all uncompiled files in batch mode, causing even more delay the first time the files are compiled. However, after this initial delay, the compilation delay is eliminated by subsequent access to the file.

When BatchMode is true (default) why is it trying to recompile the service? (As the exception says "compile-time error")

Am I missing something?

+3


source to share





All Articles