Prevent driver load failures from objects
There's been an intermittent issue where getting a list of all drivers would fail to get all defined classes. With recent local tests, once it got 103 drivers, but several times it got 69 drivers. This appears to be from exceptions thrown while loading the decorated classes with various cinder.objects classes not being defined. To get around this, this adds an explicit load of all cinder.objects before attempting to get the driver classes. Change-Id: Ief4a93ec2d8256424166c7bf3b9d48a79a6e5e54
This commit is contained in:
parent
e90d1b01f6
commit
d1166474ab
@ -18,6 +18,11 @@ import argparse
|
||||
import os
|
||||
|
||||
from cinder.interface import util
|
||||
from cinder import objects
|
||||
|
||||
|
||||
# Object loading can cause issues loading drivers, force it up front
|
||||
objects.register_all()
|
||||
|
||||
|
||||
parser = argparse.ArgumentParser(prog="generate_driver_list")
|
||||
|
Loading…
x
Reference in New Issue
Block a user