Hi, I need to call a certain Oracle database procedure - every time my rails application starts (and a valid cgi session exists) to set up my database context package for the user who is using my application - and every time my rails application finishes, to unset this context but I have no idea how to configure this in rails. (e.g. in Apache-ASP-Perl exist events like ''ScriptOnStart'' and ''ScriptOnEnd'' which would solve my problem.) Thanks! Peter
Rails provides full session support, and can use the DB to back it via ActiveRecordStore. -- -- Tom Mornini On Oct 13, 2005, at 3:29 AM, Peter Sänger wrote:> I need to call a certain Oracle database procedure > - every time my rails application starts (and a valid cgi session > exists) to > set up my database context package for the user who is using my > application > - and every time my rails application finishes, to unset this context > but I have no idea how to configure this in rails. > > (e.g. in Apache-ASP-Perl exist events like ''ScriptOnStart'' and > ''ScriptOnEnd'' > which would solve my problem.)
sounds to me like you want filters http://rails.rubyonrails.com/classes/ActionController/Filters/ClassMethods.html On 10/13/05, Peter Sänger <p.saenger-zqRSA4oDUWwb1SvskN2V4Q@public.gmane.org> wrote:> Hi, > > I need to call a certain Oracle database procedure > - every time my rails application starts (and a valid cgi session exists) to > set up my database context package for the user who is using my application > - and every time my rails application finishes, to unset this context > but I have no idea how to configure this in rails. > > (e.g. in Apache-ASP-Perl exist events like ''ScriptOnStart'' and ''ScriptOnEnd'' > which would solve my problem.) > > Thanks! > > Peter > > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails >
Hi, On Thursday 13 October 2005 19:00, Chris Hall wrote:> sounds to me like you want filtersyes, this helps a bit. Thanks!> http://rails.rubyonrails.com/classes/ActionController/Filters/ClassMethods. >html > > On 10/13/05, Peter Sänger <p.saenger-zqRSA4oDUWwb1SvskN2V4Q@public.gmane.org> wrote: > > Hi, > > > > I need to call a certain Oracle database procedure > > - every time my rails application starts (and a valid cgi session exists) > > to set up my database context package for the user who is using my > > application - and every time my rails application finishes, to unset this > > context but I have no idea how to configure this in rails. > > > > (e.g. in Apache-ASP-Perl exist events like ''ScriptOnStart'' and > > ''ScriptOnEnd'' which would solve my problem.) > > > > Thanks! > > > > Peter > > > > _______________________________________________ > > Rails mailing list > > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > > http://lists.rubyonrails.org/mailman/listinfo/rails > > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails