Actions
Bug #54355
opendbstore: confusing use of virtual inheritance for DBOps
% Done:
0%
Source:
Tags:
dbstore
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature (v1):
Crash signature (v2):
Description
virtual inheritance is usually a sign that class hierarchies are too complicated. here it's used because each SQL op derives from DBOp
twice:
class SQLInsertUser -> class SQLiteDB -> class rgw::store::DBOp class SQLInsertUser -> class rgw::store::InsertUserOp -> class rgw::store::DBOp
SQLiteDB
is derived from DB
, which should be global (per-database, at least) to the application. so it's unexpected that SQLiteDB
derives from DBOp
, and that each SQL op derives from SQLiteDB
rather than storing a pointer to the 'global' one
Actions