Commit 07705473 authored by Ramya Authappan's avatar Ramya Authappan

Merge branch 'egb-search-nightly-cache-time' into 'master'

Consolidate wait for elasticsearch cache

See merge request gitlab-org/gitlab!48980
parents fc8fac12 ba5ef216
......@@ -26,10 +26,17 @@ module QA
es.click_submit
end
end
sleep(90)
# wait for the change to propagate before inserting records or else
# Gitlab::CurrentSettings.elasticsearch_indexing and
# Elastic::ApplicationVersionedSearch::searchable? will be false
# this sleep can be removed after we're able to query logs via the API
# as per this issue https://gitlab.com/gitlab-org/quality/team-tasks/issues/395
end
def fabricate_via_api!
@es_enabled ? api_put : resource_web_url(api_get)
sleep(90)
end
def resource_web_url(resource)
......
......@@ -21,12 +21,6 @@ module QA
before do
unless elasticsearch_original_state_on?
QA::EE::Resource::Settings::Elasticsearch.fabricate_via_api!
sleep(90)
# wait for the change to propagate before inserting records or else
# Gitlab::CurrentSettings.elasticsearch_indexing and
# Elastic::ApplicationVersionedSearch::searchable? will be false
# this sleep can be removed after we're able to query logs via the API
# as per this issue https://gitlab.com/gitlab-org/quality/team-tasks/issues/395
end
Resource::Repository::Commit.fabricate_via_api! do |commit|
......
......@@ -22,12 +22,6 @@ module QA
before do
unless elasticsearch_original_state_on?
QA::EE::Resource::Settings::Elasticsearch.fabricate_via_api!
sleep(90)
# wait for the change to propagate before inserting records or else
# Gitlab::CurrentSettings.elasticsearch_indexing and
# Elastic::ApplicationVersionedSearch::searchable? will be false
# this sleep can be removed after we're able to query logs via the API
# as per this issue https://gitlab.com/gitlab-org/quality/team-tasks/issues/395
end
Resource::Repository::Commit.fabricate_via_api! do |commit|
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment