Skip to content

Commit d43c620

Browse files
committed
fix flapping lucene-benchmarks health; add some debugging
1 parent d714c57 commit d43c620

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

examples/githubsearch/status.py

+5-2
Original file line numberDiff line numberDiff line change
@@ -72,9 +72,12 @@ def check_all_benchy():
7272
('lucenebench/sparseResults', 16),
7373
('lucenebench/checkIndexTime', 1),
7474
('lucenebench/github_pr_counts', 1)):
75-
75+
76+
t0 = time.time()
77+
print(f'now check {name}, expected_count={expected_count}')
7678
max_age, count = check_one_benchy_page(name, expected_count)
7779
ages.append(f'{max_age.total_seconds()/3600:.2f}')
80+
print(f' took {time.time()-t0:.2f} sec; age {max_age.total_seconds():.2f} sec')
7881
total_count += count
7982
return ', '.join(ages), total_count
8083

@@ -110,7 +113,7 @@ def application(environ, start_response):
110113
elif what == 'lucene-benchmarks':
111114
age = time.time() - status_lucene_benchmarks[1]
112115

113-
if age > 60:
116+
if age > 900:
114117
# background status thread died!
115118
http_status = f'500 Thread died {age:.2f} seconds ago'
116119
else:

0 commit comments

Comments
 (0)