Re: [spr32061] Problem with Allegroserve+Allegrocache
mikel evins <[email protected]> Thu, 7 Sep 2006 09:46:46 -0600
| Newsgroups | gmane.lisp.allegro |
|---|---|
| Message-ID | <[email protected]> |
On Sep 6, 2006, at 10:36 PM, John Foderaro wrote: > > It *should* be the case that specifying the database like > this is sufficient > > (db.ac:retrieve-from-index 'dbs::user 'dbs::username username :db > $users) > > > However to be safe it's better to do this: > > (let ((*allegrocache* $users)) > (db.ac:retrieve-from-index 'dbs::user 'dbs::username username)) > > This establishes the current database for all functions > that retrieve-from-index might call. > (If this fixes it let me know as special binding, while good style, > should not be necessary in this case). It does solve the problem; thanks. > > > Stepping back I'm concerned that you're potentially > using a single database connection in more than one thread > (since AllegroServe is multithreaded). This can lead > to problems. > > In the more recent AllegroCache distributions you'll > find a find called doc/acweb.pdf that goes into detail > on how to use AllegroCache and AllegroServe together > and not run into problems with multiple threads. > > The latest distributions of AllegroCache can be found here: > > http://www.franz.com/products/allegrocache/download/dist/download And thanks again for that pointer; I'll certainly read it avidly. Thanks for everything! --me