Michael Pasternak has posted comments on this change.

Change subject: restapi: #838270 - Support View Of System Configuration
......................................................................


Patch Set 11: I would prefer that you didn't submit this

(13 inline comments)

....................................................
File 
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/action/UpdateConfigurationValueParameters.java
Line 2: 
Line 3: import org.ovirt.engine.core.common.queries.ConfigurationValues;
Line 4: import org.ovirt.engine.core.compat.Version;
Line 5: 
Line 6: public class UpdateConfigurationValueParameters extends 
VdcActionParametersBase {
this parameter class is not used
Line 7: 
Line 8:     private static final long serialVersionUID = 7243799194401825747L;
Line 9: 
Line 10:     private ConfigurationValues item;


....................................................
File 
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/action/VdcActionType.java
Line 215:     AddEventSubscription(1100, QuotaDependency.NONE),
Line 216:     RemoveEventSubscription(1101, QuotaDependency.NONE),
Line 217: 
Line 218:     // Config
Line 219:     UpdateConfigurationValue(1302, ActionGroup.CONFIGURE_ENGINE, 
false, QuotaDependency.NONE),
these action groups are not used
Line 220:     ReloadConfigurations(1301, ActionGroup.CONFIGURE_ENGINE, false, 
QuotaDependency.NONE),
Line 221: 
Line 222:     // Gluster
Line 223:     CreateGlusterVolume(1400, ActionGroup.CREATE_GLUSTER_VOLUME, 
QuotaDependency.NONE),


....................................................
File 
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/AuditLogType.java
Line 656: 
Line 657:     RELOAD_CONFIGURATIONS_SUCCESS(1010),
Line 658:     RELOAD_CONFIGURATIONS_FAILURE(1011),
Line 659:     USER_UPDATE_CONFIGURATION_ITEM(1012),
Line 660:     USER_FAILED_UPDATE_CONFIGURATION_ITEM(1013),
these two are not relevant
Line 661: 
Line 662:     // Authentication
Line 663:     USER_ACCOUNT_DISABLED_OR_LOCKED(1100, 
AuditLogTimeInterval.HOUR.getValue()),
Line 664:     USER_ACCOUNT_PASSWORD_EXPIRED(1101, 
AuditLogTimeInterval.HOUR.getValue()),


....................................................
File 
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/config/Config.java
Line 54:         return ConfigUtil.resolvePath(Config.<String> 
GetValue(ConfigValues.DataDir),
Line 55:                 Config.<String> 
GetValue(ConfigValues.oVirtISOsRepositoryPath));
Line 56:     }
Line 57: 
Line 58:     public static void SetValue(String name, String value, String 
version) {
this method should not be added as we not supporting update in this stage
Line 59:         getConfigUtils().SetValue(name, value, version);
Line 60:     }
Line 61: 


....................................................
File 
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/config/IConfigUtilsInterface.java
Line 100:     <T> T GetValue(ConfigValues configValue, String version);
Line 101: 
Line 102:     <T> T GetValue(ConfigValues value, String version, boolean 
includeGenerated);
Line 103: 
Line 104:     void SetValue(String name, String value, String version);
this method should not be added as we not supporting update in this stage
Line 105: 


....................................................
File 
backend/manager/modules/dal/src/main/java/org/ovirt/engine/core/dal/VdcBllMessages.java
Line 23:     VAR__TYPE__VM_DISK,
Line 24:     VAR__TYPE__BOOKMARK,
Line 25:     VAR__TYPE__VM_TICKET,
Line 26:     VAR__TYPE__PERMISSION,
Line 27:     VAR__TYPE__CONFIGURATION,
this VAR_TYPE should not be added as we not supporting update in this stage
Line 28: 
Line 29:     // Gluster types
Line 30:     VAR__TYPE__GLUSTER_VOLUME,
Line 31:     VAR__TYPE__GLUSTER_VOLUME_OPTION,


....................................................
File backend/manager/modules/dal/src/main/resources/bundles/AppErrors.properties
Line 223: VAR__TYPE__INTERFACE=$type Interface
Line 224: VAR__TYPE__VM_DISK=$type Virtual Machine Disk
Line 225: VAR__TYPE__BOOKMARK=$type Bookmark
Line 226: VAR__TYPE__VM_TICKET=$type Virtual Machine Ticket
Line 227: VAR__TYPE__CONFIGURATION=$type Configuration Item
this VAR_TYPE should not be added as we not supporting update in this stage
Line 228: VAR__TYPE__STORAGE__CONNECTION=$type Storage Connection
Line 229: VAR__TYPE__STORAGE__DOMAIN=$type Storage
Line 230: VAR__TYPE__STORAGE__POOL=$type Repository
Line 231: VAR__TYPE__USER_FROM_VM=$type User to VM


....................................................
File 
backend/manager/modules/restapi/interface/definition/src/main/resources/rsdl_metadata.yaml
Line 3161:       parameterType: null
Line 3162:       signatures: []
Line 3163:     urlparams: {}
Line 3164:     headers:
Line 3165:       Filter: {value: true|false, required: false}      
WS


....................................................
File 
backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/restapi/resource/BackendConfigurationItemsResource.java
Line 28:                         new 
GetConfigurationValuesQueryParameters(false), null);
Line 29:         return addActionLinks(mapCollection(itemsMap));
Line 30:     }
Line 31: 
Line 32:     private ConfigurationItems 
mapCollection(Map<KeyValuePairCompat<ConfigurationValues, String>, Object> 
itemsMap) {
wouldn't make sense moving this code to dedicated mapper?
Line 33:         ConfigurationItems items = new ConfigurationItems();
Line 34:         for (Entry<KeyValuePairCompat<ConfigurationValues, String>, 
Object> entry : itemsMap.entrySet()) {
Line 35:             ConfigurationItem item = getMapper(Entry.class, 
ConfigurationItem.class).map(entry, null);
Line 36:             // item may be null because of missing mapping, and we 
don't want to fail the operation for that,


....................................................
File 
backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/restapi/resource/BackendHostHookResource.java
Line 21
Line 22
Line 23
Line 24
Line 25
i'm not sure this change is related to this patch?


....................................................
File 
backend/manager/modules/restapi/types/src/main/java/org/ovirt/engine/api/restapi/types/VersionMapper.java
Line 24:         if (model == null) {
Line 25:             model = new Version();
Line 26:         }
Line 27:         model.setMajor(entity.getMajor());
Line 28:         model.setMinor(entity.getMinor());
what about other properties?
Line 29:         return model;
Line 30:     }
Line 31: 
Line 32:     /**


Line 42:             model.setNonSpecific(true);
Line 43:         } else {
Line 44:             model = VersionUtils.parseVersion(entity);
Line 45:             model.setBuild(null); // API currently doesn't support 
build
Line 46:             model.setRevision(null); // API currently doesn't support 
revision
what about other properties?
Line 47:         }
Line 48:         return model;
Line 49:     }
Line 50: 


Line 51:     @Mapping(from = Version.class, to = 
org.ovirt.engine.core.compat.Version.class)
Line 52:     public static org.ovirt.engine.core.compat.Version map(Version 
model, org.ovirt.engine.core.compat.Version entity) {
Line 53:         // Note: currently API layer only supports major & minor 
properties of Version, but this may change in the
Line 54:         // future (to include build and revision as well).
Line 55:         return new 
org.ovirt.engine.core.compat.Version(model.getMajor(), model.getMinor());
i'd prefer all properties get mapped
Line 56:     }
Line 57: 


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

Gerrit-MessageType: comment
Gerrit-Change-Id: I3d5cf3a09cfbf4bfb7586ba296e13f71386c396f
Gerrit-PatchSet: 11
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Ori Liel <ol...@redhat.com>
Gerrit-Reviewer: Michael Pasternak <mpast...@redhat.com>
Gerrit-Reviewer: Ori Liel <ol...@redhat.com>
Gerrit-Reviewer: Yair Zaslavsky <yzasl...@redhat.com>
_______________________________________________
Engine-patches mailing list
Engine-patches@ovirt.org
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to