Change in ovirt-engine[ovirt-engine-4.0]: core: Fix wrong db initialization

Tal Nisan has submitted this change and it was merged. Change subject: core: Fix wrong db initialization ...................................................................... core: Fix wrong db initialization Before this patch, when pool got empty during its initialization, and tried to write log about it into AuditLog, NPE was thrown, because DbFacade wasn't initialized yet. Such NPE brought several singletons down blocking ear from being deployed. The reason for that is probably that there's a code using org.ovirt.engine.core.dal.dbbroker.DbFacade#getInstance which gets initialized only after DbFacade bean is properly constructed. Injecting DbFacade into MacPoolPerCluster seems to fix the issue, since DbFacade gets initialized during inject and thus getInstance will return correct non-null instance when called. Change-Id: I3e44d5da98b31f502252f9418a068cb509408d4d Bug-Url: https://bugzilla.redhat.com/1343332 Signed-off-by: Martin Mucha <mmucha@redhat.com> --- M backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/Backend.java M backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/network/macpool/MacPoolPerDc.java 2 files changed, 4 insertions(+), 2 deletions(-) Approvals: Martin Mucha: Verified Alona Kaplan: Looks good to me, approved Jenkins CI: Passed CI tests -- To view, visit https://gerrit.ovirt.org/59527 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: merged Gerrit-Change-Id: I3e44d5da98b31f502252f9418a068cb509408d4d Gerrit-PatchSet: 2 Gerrit-Project: ovirt-engine Gerrit-Branch: ovirt-engine-4.0 Gerrit-Owner: Martin Mucha <mmucha@redhat.com> Gerrit-Reviewer: Alona Kaplan <alkaplan@redhat.com> Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Martin Mucha <mmucha@redhat.com> Gerrit-Reviewer: Tal Nisan <tnisan@redhat.com> Gerrit-Reviewer: gerrit-hooks <automation@ovirt.org>
participants (1)
-
tnisan@redhat.com