Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Re: Install updated version of script such that running instances cannot use an inconsistent state

by tobyink (Abbot)
on Jan 28, 2013 at 21:19 UTC ( #1015761=note: print w/ replies, xml ) Need Help??


in reply to Install updated version of script such that running instances cannot use an inconsistent state

Write your installation script so that it does things in the following order:

  1. Deletes the existing CGI scripts
  2. Pause for one second
  3. Deletes the existing modules
  4. Installs replacement modules
  5. Installs replacement CGI scripts
package Cow { use Moo; has name => (is => 'lazy', default => sub { 'Mooington' }) } say Cow->new->name
  • Comment on Re: Install updated version of script such that running instances cannot use an inconsistent state

Replies are listed 'Best First'.
Re^2: Install updated version of script such that running instances cannot use an inconsistent state
by ambrus (Abbot) on Jan 28, 2013 at 21:28 UTC

    How do you know that one second is enough? A CGI script could run for longer than that sometimes.

      True, but I'd generally expect it to have at least finished compiling.

      package Cow { use Moo; has name => (is => 'lazy', default => sub { 'Mooington' }) } say Cow->new->name

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1015761]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others exploiting the Monastery: (6)
As of 2016-06-30 09:44 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    My preferred method of making French fries (chips) is in a ...











    Results (392 votes). Check out past polls.