Frank Kobzik has posted comments on this change.

Change subject: backend: Control virtio rng device
......................................................................


Patch Set 21: Verified+1

(1 comment)

http://gerrit.ovirt.org/#/c/18176/21/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/AbstractRngDeviceCommand.java
File 
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/AbstractRngDeviceCommand.java:

Line 28: getRngDevice
To Omer and Roy: I actually added back the null checks here despite the 
@NotNull validation in params because @NotNull in params class doesn't save me 
- it is checked just before canDoAction() and that's late - the code in this 
constructor would fail with NPEx (because the @NotNull wouldn't be applied yet).

I was thinking of moving this initialization code to common method that would 
be called before executeCommand() of subclasses, but the the attributes to be 
set also at the time canDoAction() is called. I could also to put the 
initialization code to canDoAction - but that's not very nice.

I think this is the best solution.


-- 
To view, visit http://gerrit.ovirt.org/18176
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Ifc26a484c84244074426f4b0c790e2cc4ebb8da6
Gerrit-PatchSet: 21
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Frank Kobzik <[email protected]>
Gerrit-Reviewer: Arik Hadas <[email protected]>
Gerrit-Reviewer: Frank Kobzik <[email protected]>
Gerrit-Reviewer: Martin Betak <[email protected]>
Gerrit-Reviewer: Omer Frenkel <[email protected]>
Gerrit-Reviewer: Roy Golan <[email protected]>
Gerrit-Reviewer: [email protected]
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to