How the IIS7 handle a auth module? Memory scope?
as those who worked on such a prooject prolly know this site:
http://learn.iis.net/page.aspx/170/developing-a-module-using-net/

There Mike Volodarsky made a very good post how to create you own security auth extension for the IIS7.
I took this and modified to my own need. I am fetching the basci auth credentials and call a external web service to authenticate the user from a different active directory domain.
Works fine so far.

Calling the web service take some time and each request, site, resource (image, stylesheet, javascript file, etc.) make the IIS7 to call the module and authenticate again.

I am not aware how the IIS7 handle this module so I decided to make a own sql-table based security token with a 10minutes life time. So my code now check if this token available and gratns acccess or if not, call the web service to authenticate again.

I developed eveything and works well. In production I ran into worse timeouts and found out that my sql connection is the problem. The connection pool overfloaded. I fixed this with a bad workaround to set the pool size to very big number.

Now here my problem / question:
Anyone knows if this module stay in memory in any way so I can store a token in memory (any application pool scope)? The idea is to store the tokens in memory while the application runs. But I can't find any informations help me to find out how the module is handled from the IIS7 and if my idea is a solution for the problem.

How the IIS7 handle a auth module? Memory scope?
===

as those who worked on such a prooject prolly know this site:
http://learn.iis.net/page.aspx/170/developing-a-module-using-net/

There Mike Volodarsky made a very good post how to create you own security auth extension for the IIS7.
I took this and modified to my own need. I am fetching the basci auth credentials and call a external web service to authenticate the user from a different active directory domain.
Works fine so far.

Calling the web service take some time and each request, site, resource (image, stylesheet, javascript file, etc.) make the IIS7 to call the module and authenticate again.

I am not aware how the IIS7 handle this module so I decided to make a own sql-table based security token with a 10minutes life time. So my code now check if this token available and gratns acccess or if not, call the web service to authenticate again.

I developed eveything and works well. In production I ran into worse timeouts and found out that my sql connection is the problem. The connection pool overfloaded. I fixed this with a bad workaround to set the pool size to very big number.

Now here my problem / question:
Anyone knows if this module stay in memory in any way so I can store a token in memory (any application pool scope)? The idea is to store the tokens in memory while the application runs. But I can't find any informations help me to find out how the module is handled from the IIS7 and if my idea is a solution for the problem.
