On 10/22/07, Isaac Csandl <[EMAIL PROTECTED]> wrote: > > Hi, > > I noticed the docs on upgrading to 0.4 say "objectstore becomes > session". > > I think this change will create a situation where you could easily > shoot yourself in the foot when developing in Pylons (IIRC, TurboGears > too). There, session normally refers to the user/browser session. It > is automatically imported as 'session' into every controller. > > Sure, you could import Elixir's session under a different name, but > it's going to be confusing and hard to remember and keep track of it > as you develop the app, especially if it's a complex one. > > So... > > +1 to _not_ deprecate objectstore, or use a name other than > 'session'.
That move was done to address the complaint that SQLAlchemy use the word session and it was not immediately obvious that when you are using Elixir objectstore, it is in fact a session in disguise and you should refer to that part of SQLAlchemy documentation for further information. I might be ok (although very reluctant) to use another name (like global_session, db_session, elixir_session or similar) to not collide with other concept named session as long as it is clear you are talking to a session. That said, that really feels like something which should be done either in Pylons or in your own code. As a side note, SQLAlchemy 0.4 provides a few interesting options you can pass to your session, so you'd have to either define another session or configure the default one anyway. I'd also be interested to know what people using Pylons with raw SQLAlchemy do as they must run into almost the same "problem". Defining one global (and specialized to your needs) session for your whole program then importing that in all your modules doesn't seem so hard to me. I'd really appreciate input from other people on this one. -- Gaƫtan de Menten http://openhex.org --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "SQLElixir" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/sqlelixir?hl=en -~----------~----~----~----~------~----~------~--~---
