• Kirill Smelkov's avatar
    go/zodb: DB - application-level handle to database (very draft) · 533f0c73
    Kirill Smelkov authored
    DB represents a handle to database at application level and contains pool
    of connections. DB.Open opens database connection. The connection will be
    automatically put back into DB pool for future reuse after corresponding
    transaction is complete. DB thus provides service to maintain live objects
    cache and reuse live objects from transaction to transaction.
    
    Note that it is possible to have several DB handles to the same database.
    This might be useful if application accesses distinctly different sets of
    objects in different transactions and knows beforehand which set it will be
    next time. Then, to avoid huge cache misses, it makes sense to keep DB
    handles opened for every possible case of application access.
    
    TODO handle invalidations.
    533f0c73
time.go 2.73 KB