|
|
Browse by Tags
All Tags » asp.net » IHttpModule (RSS)
-
db4o does not have a built-in pool mechanism but implementing is not so hard :)
Have something like Queue or Stack in your pooling class and implementing borrow and return method should be easy.
Instead of opening container everytime page loads, you should get it from pool. and then it doesnt really matter which container you have in sub ...
-
Here it is. I made it on the fly, hope it's ok.
Server and Client are created and opened only when explicitly requested. No longer needed BeginRequest event handler has been removed.
using System;using System.Configuration;using System.Web;using com.db4o;namespace MyProject.DataAccess{ /// <summary> /// ...
-
Eric Falsken:
You deserve a big kiss. This is EXCELENT way to use db4o and ASP.NET. If you don't mind, I'm going to use this from now on, myself.
Thank you very much Eric, but to tell the truth this is not completely my own work; instead it's an idea I took from a best practice on how Sessions are handled with NHibernate, which in this ...
-
I've just come across with a solution for dealing with this problem in ASP.NET, which relies with IHttpModule interface. Here is the code:
using System;using System.Configuration;using System.Web;using com.db4o;
namespace MyProject.DataAccess{
public class Db4oHttpModule : ...
|
|
|