Re: Grabbing sequence values blocks in consecutive order: Need a guaranteed method.
- From: Christo Kutrovsky <kutrovsky.oracle@xxxxxxxxx>
- To: afatkulin@xxxxxxxxx
- Date: Wed, 25 Mar 2009 12:51:18 -0400
I agree as well, the process in the article is not safe. In theory, you could use DBMS_LOCK to serialize the check if running, but why bother when you can just use DBMS_LOCK . -- Christo Kutrovsky Senior DBA The Pythian Group - www.pythian.com I blog at http://www.pythian.com/blogs/ On Wed, Mar 25, 2009 at 11:40 AM, Alex Fatkulin <afatkulin@xxxxxxxxx> wrote: > Riyaj -- I don't like that article either. > > the example in that article is dangerous at best > > reading and setting module are not an atomic instructions > > how about: > > T1: am_dep1 check for am_dep2 -- not running, gets preempted by the OS > before it sets itself > T2: am_dep2 check for am_dep1 -- not running > T3: am_dep2 registers itself and starts running > T4: am_dep1 gets into run queue again and registers itself and starts running > > now what? > > not even mention that on SMP system both processes might checks the > status at the same time with the same outcome... > > On Wed, Mar 25, 2009 at 11:20 AM, Riyaj Shamsudeen > <riyaj.shamsudeen@xxxxxxxxx> wrote: >> Hello fmhabash and Amar >> >> I think, it is not a good idea to use v$session or dbms_application_info. > > -- > Alex Fatkulin, > http://afatkulin.blogspot.com > http://www.linkedin.com/in/alexfatkulin > -- > http://www.freelists.org/webpage/oracle-l > > > -- Christo Kutrovsky Senior DBA The Pythian Group - www.pythian.com I blog at http://www.pythian.com/blogs/ -- http://www.freelists.org/webpage/oracle-l
- References:
- RE: Grabbing sequence values blocks in consecutive order: Need a guaranteed method.
- From: FmHabash
- Re: Grabbing sequence values blocks in consecutive order: Need a guaranteed method.
- From: Riyaj Shamsudeen
- Re: Grabbing sequence values blocks in consecutive order: Need a guaranteed method.
- From: Alex Fatkulin
- RE: Grabbing sequence values blocks in consecutive order: Need a guaranteed method.
Other related posts:
- » Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - FmHabash
- » RE: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - Bobak, Mark
- » RE: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - Kenneth Naim
- » RE: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - FmHabash
- » RE: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - Powell, Mark D
- » RE: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - Kenneth Naim
- » RE: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - Mark W. Farnham
- » Re: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - Riyaj Shamsudeen
- » Re: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - Amar Kumar Padhi
- » RE: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - FmHabash
- » RE: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - Bobak, Mark
- » Re: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - Riyaj Shamsudeen
- » Re: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - Alex Fatkulin
- » RE: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - Bobak, Mark
- » Re: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - Christo Kutrovsky
- » RE: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - Amar Kumar Padhi
- » Re: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - Alex Fatkulin
- » Re: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - Greg Rahn
- » Re: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - Jared Still
- » Re: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - Amar Kumar Padhi
- » Re: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - Alex Fatkulin
- » Re: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - Niall Litchfield
- » Re: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - Niall Litchfield
- » RE: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - FmHabash
- » Re: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - Jack van Zanen
- » Re: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - Yechiel Adar
- » Re: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - Amar Kumar Padhi
- » RE: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - FmHabash
- » Re: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - Jared Still
- » Re: Grabbing sequence values blocks in consecutive order: Need a guaranteed method. - Jack van Zanen