Shortened the anvil-daemon job start up delay.

Signed-off-by: digimer <mkelly@alteeve.ca>
main
digimer 7 months ago
parent 6826b12188
commit 8e53993f67
  1. 4
      Anvil/Tools/Database.pm
  2. 2
      Anvil/Tools/Network.pm
  3. 4
      tools/anvil-daemon

@ -1361,8 +1361,8 @@ sub connect
} }
# If we're a Striker, see if we're configured. # If we're a Striker, see if we're configured.
my $local_host_type = $anvil->Get->host_type(); my $local_host_type = $anvil->Get->host_type({debug => $debug});
my $local_host_uuid = $anvil->Get->host_uuid(); my $local_host_uuid = $anvil->Get->host_uuid({debug => $debug});
my $db_count = keys %{$anvil->data->{database}}; my $db_count = keys %{$anvil->data->{database}};
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => $debug, list => { $anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => $debug, list => {
local_host_type => $local_host_type, local_host_type => $local_host_type,

@ -4785,7 +4785,7 @@ sub wait_for_network
's4:state' => $state, 's4:state' => $state,
}}); }});
if (($state eq "activated") or ($state == 1)) if (($state eq "activated") or ($state eq "1"))
{ {
$anvil->data->{network}{watch}{$interface_name}{ready} = 1; $anvil->data->{network}{watch}{$interface_name}{ready} = 1;
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => $debug, list => { $anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => $debug, list => {

@ -1567,10 +1567,10 @@ sub run_jobs
time_since_start => $time_since_start, time_since_start => $time_since_start,
start_time => $start_time, start_time => $start_time,
}}); }});
if ($time_since_start < 60) if ($time_since_start < 30)
{ {
# Log that we'll start jobs in X seconds. # Log that we'll start jobs in X seconds.
my $will_start_in = 60 - $time_since_start; my $will_start_in = 30 - $time_since_start;
$anvil->Log->entry({source => $THIS_FILE, line => __LINE__, level => 2, key => "message_0326", variables => { will_start_in => $will_start_in }}); $anvil->Log->entry({source => $THIS_FILE, line => __LINE__, level => 2, key => "message_0326", variables => { will_start_in => $will_start_in }});
return(0); return(0);
} }

Loading…
Cancel
Save