do not start genesis data fetching periodically

From this point genesis data fetching will start and will
be retried on a task failure. Also, this PR disables genesis
data fetcher process by default because most our users won't
know that they should set chain spec for it.
pull/2594/head
Ayrat Badykov 5 years ago
parent e9d7b7cf51
commit 2b6f7eff78
No known key found for this signature in database
GPG Key ID: B44668E265E9396F
  1. 2
      apps/explorer/config/config.exs
  2. 1
      apps/explorer/lib/explorer/chain_spec/genesis_data.ex

@ -27,7 +27,7 @@ config :explorer, Explorer.Counters.AverageBlockTime,
enabled: true, enabled: true,
period: average_block_period period: average_block_period
config :explorer, Explorer.ChainSpec.GenesisData, enabled: true, chain_spec_path: System.get_env("CHAIN_SPEC_PATH") config :explorer, Explorer.ChainSpec.GenesisData, enabled: false, chain_spec_path: System.get_env("CHAIN_SPEC_PATH")
config :explorer, Explorer.Chain.Cache.BlockNumber, enabled: true config :explorer, Explorer.Chain.Cache.BlockNumber, enabled: true

@ -18,7 +18,6 @@ defmodule Explorer.ChainSpec.GenesisData do
@impl GenServer @impl GenServer
def init(_) do def init(_) do
:timer.send_interval(@interval, :import)
Process.send_after(self(), :import, @interval) Process.send_after(self(), :import, @interval)
{:ok, %{}} {:ok, %{}}

Loading…
Cancel
Save