Keeping State of Objects Without Session

Sep 25, 2008 at 4:13 PM

I'm having trouble understanding this part of the source code. I know that all objects provided by the ESP Search API are non-serializable... so how do you keep the state of this objects without using Session State? What was your workaround?

Oct 13, 2008 at 1:40 PM
We are using the request scope for that.

All WebParts can contribute search parameters to an instance of IESPSearchSettings which is kept in the request scope. This can be done by overriding the ConfigureSearch() method which is called in the
webpart OnInit lifecycle method.
This object is later used (In the CreateChildControls lifecycle) to perform the search. Once the search is performed the results are injected to the webpart in the method SetSearchResult.
You should be able to get some more information on that in the ESPSearchWebParts\src\UI\ESPSearchWebPart.cs which implements the whole lifecycle and creates the used UCF and Search Settings object.


Jan 29, 2010 at 9:03 PM
Edited Feb 1, 2010 at 6:28 PM


Can anyone help me out in understanding this bit more clear.

I would be really thankful if someone could help me with this.