[ruby testing]: experimental change to grpc_class_init_test (#32337)

Let's see if this fixes the "Bus error" flakes that have been happening
in CI.

If it does, then we can narrow things down a bit. If flakes continue,
then we can revert this PR.
pull/32398/head
apolcyn 2 years ago committed by GitHub
parent dd07fd8669
commit 4777db3003
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 15
      src/ruby/end2end/grpc_class_init_client.rb
  2. 5
      src/ruby/end2end/grpc_class_init_test.rb

@ -36,13 +36,15 @@ end
def run_gc_stress_test(test_proc)
GC.disable
construct_many(test_proc)
# TODO(b/266212253): run construct_many
# in this test after "Bus error" flakes are fixed.
run_default_test(test_proc)
GC.enable
construct_many(test_proc)
run_default_test(test_proc)
GC.start
construct_many(test_proc)
run_default_test(test_proc)
end
def run_concurrency_stress_test(test_proc)
@ -58,11 +60,10 @@ end
# default (no gc_stress and no concurrency_stress)
def run_default_test(test_proc)
thd = Thread.new do
test_proc.call
end
# TODO(b/266212253): re-enable the extra thread
# in this test after the "Bus error" flakes of this
# test are fixed.
test_proc.call
thd.join
end
# rubocop:disable Metrics/CyclomaticComplexity

@ -30,7 +30,10 @@ def main
# do a few runs for each config
4.times do
native_grpc_classes.each do |grpc_class|
['', 'gc', 'concurrency'].each do |stress_test_type|
# TODO(b/266212253): re-enable the "concurrency" mode
# of this test after the "Bus error" flakes of this
# test are fixed.
['', 'gc'].each do |stress_test_type|
STDERR.puts 'start client'
this_dir = File.expand_path(File.dirname(__FILE__))
client_path = File.join(this_dir, 'grpc_class_init_client.rb')

Loading…
Cancel
Save