Alon Bar-Lev has posted comments on this change.
Change subject: engine: Add infrastructure code for removal of parameter classes
......................................................................
Patch Set 8:
(2 comments)
....................................................
File
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/utils/VdcParameter.java
Line 59: Guid guid = new Guid(guidStr);
Line 60: if (parametersMap.containsKey(guid)) {
Line 61: throw new InvalidParameterGuidException(name, guidStr,
parametersMap.get(guid));
Line 62: }
Line 63: parametersMap.put(guid, new VdcParameter(name, javaType,
guid));
if you have two sync methods, both will not be able to run at same time, not
only the method you are sync, right?
won't it better to sync over the map object only when modifying it?
it is true that currently it does not that important... but I know allon and
roy do not like method level sync.
Line 64: return parametersMap.get(guid);
Line 65: }
Line 66:
Line 67: /**
....................................................
File
backend/manager/modules/utils/src/main/java/org/ovirt/engine/core/utils/serialization/json/JsonObjectDeserializer.java
Line 101: private static class VdcParameterDeserializer extends
KeyDeserializer {
Line 102: @Override
Line 103: public VdcParameter deserializeKey(String key,
DeserializationContext ctxt) throws IOException {
Line 104: String[] tokens = key.split(";");
Line 105: return VdcParameter.getExisting(tokens[2]);
you invent it... current version=0... in future if you change the format you
should also change version, so that you know how to parse.
Line 106: }
Line 107: }
--
To view, visit http://gerrit.ovirt.org/20414
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: I6a0970e492c0eff561888a46b02e47645ff68fc3
Gerrit-PatchSet: 8
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Ravi Nori <[email protected]>
Gerrit-Reviewer: Alon Bar-Lev <[email protected]>
Gerrit-Reviewer: Barak Azulay <[email protected]>
Gerrit-Reviewer: Liran Zelkha <[email protected]>
Gerrit-Reviewer: Ravi Nori <[email protected]>
Gerrit-Reviewer: Yaniv Bronhaim <[email protected]>
Gerrit-Reviewer: mooli tayer <[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