Autoscaled nodes do not check database layout
If we got thus far to start autoscaled nodes, the datastore must be
primed. This shaves off almost 2 minutes in start up time.
@@ -3300,6 +3300,17 @@ class Djinn
Djinn.log_info('Waiting for DB services ... ')
threads.each { |t| t.join }
+ # Autoscaled nodes do not need to check if the datastore is primed: if
+ # we got this far, it must be primed.
+ am_i_autoscaled = false
+ get_autoscaled_nodes.each { |node|
+ if slave.private_ip == my_node.private_ip
+ am_i_autoscaled = true
+ Djinn.log_info("Skipping database layout check on scaled node.")
+ break
+ end
+ }
+ unless am_i_autoscaled
Djinn.log_info('Ensuring necessary database tables are present')
sleep(SMALL_WAIT) until system("#{PRIME_SCRIPT} --check > /dev/null 2>&1")
@@ -3322,6 +3333,7 @@ class Djinn
end
retries -= 1
}
+ end
if my_node.is_db_master? or my_node.is_db_slave?
@state = "Starting UAServer"
