HTTPModule and a Word Corpus
-
I'm doing a HTTPModule to summarize the text within web pages in my web server. The summarization process is with me but i need a big corpus of words to help on summarization. My problem is : Where do i put this corpus in memory so it can be acessed quickly in runtime ???? Now i have a static variable that stay in memory with the corpus and the next time a page loads it has already the static corpus in memory. I have this static variable when i call HTTPModule. I still have the problem of loading the corpus in the first time that someone loads the page... I takes a while reading it from a file. Is there any way to call my HTTPModule when the IIS starts or something like that??? Do you have any other ideas that can help me??? Where do i put the corpus in memory??? A Windows Service Works??? Can i call a Windows Service that has the corpus in memory and be fast enougth??? Thank you very much !!! :) Sorry for my English...:( Bruno Conde. pharaoh
-
I'm doing a HTTPModule to summarize the text within web pages in my web server. The summarization process is with me but i need a big corpus of words to help on summarization. My problem is : Where do i put this corpus in memory so it can be acessed quickly in runtime ???? Now i have a static variable that stay in memory with the corpus and the next time a page loads it has already the static corpus in memory. I have this static variable when i call HTTPModule. I still have the problem of loading the corpus in the first time that someone loads the page... I takes a while reading it from a file. Is there any way to call my HTTPModule when the IIS starts or something like that??? Do you have any other ideas that can help me??? Where do i put the corpus in memory??? A Windows Service Works??? Can i call a Windows Service that has the corpus in memory and be fast enougth??? Thank you very much !!! :) Sorry for my English...:( Bruno Conde. pharaoh
-
You can initialize the value for the static variable when the ASP.NET application starts using the
Application_Start
event in the Global.asax[^]. You then can use the variable for subsequent requests without recreating the variable.Yes, thats true but this is what i'm doing now. When my ASP.NET application starts i load the corpus... The problem is when the first incomming HTTP request is processed that is when corpus is load. This is very slow for the first user to see my website. I want something like when the computer loads, at startup, the aspnet_wp.exe (Worker Process) then i load the corpus... You dont know if that can be done in machine.config in ASP.NET configs?? Thanks !! Bruno Conde. pharaoh