Recently we were conducting a Performance lab for a Web based reporting service. After recording a Web test we would get this Nasty “ADO.Net session has expired” error just after the recording is over and while Visual Studio is detecting Dynamic parameters. The reason for this error could be many… like the ones mentioned in the links this, this and this.
Then we found an article that mentioned how “Promoting Dynamic Variables” could solve this issue (link). So we right-clicked the Web Recording and clicked “Promote Dynamic Variables”. But nothing happened. No dynamic variables were detected.
So we continued our research. And one of the nasty errors I was getting on my terminal was this:
This error used to show up everytime we started the Web Recorder from VSTS. Intially we ignored it and manually started the Web Recorder from the View\Explorer Bar menu option of the browser. But I decided to get rid of it by setting the following option in the Browser:
And, to our surprise, after setting this option, the Promote Dynamic Variables list box showed up. So, my guess… because VSTS could not instantiate the Recorder itself, it failed to put the required “hooks” to detect Dynamic Variables after the recording was over.
So, after a day of struggle with the nasty session error, we were finally able to record all our scripts. As they say… Alls well that ends well.