Allon Mureinik has submitted this change and it was merged.
Change subject: core: Remove member init in business entities
......................................................................
core: Remove member init in business entities
Since the upgrade to GWT 2.5.1, we've seen several cases of GWT pruning
member initialization.
To prevent these (and future) bugs, this series of patches removes all
such initializations from the packages that should be compiled by GWT.
These initialization are either moved to the appropriate
constructor(s), or removed them completely if they are redundant.
Constants with the wrong modifiers are amended to have static final, and
are allowed to be initialized directly.
As a side bonus, this patch offers a minor performance improvement, as
some of these members are now only initialized once instead of twice
(once in the member initialization and then again via a constructor
parameter).
This patch takes care of all the project's business entities, as
noted in the subject.
Change-Id: I8e8eb9ccb0e68db936489110d7f5c5828d07fab4
Signed-off-by: Allon Mureinik <amureini(a)redhat.com>
---
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/asynctasks/AsyncTaskCreationInfo.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/asynctasks/EndedTasksInfo.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/ActionGroup.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/ActionVersionMap.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/AsyncTaskStatus.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/AsyncTasks.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/AuditLog.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/BaseDisk.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/CopyVolumeType.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/DateEnumForSearch.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/DbUser.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/DiskImage.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/DiskImageBase.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/DiskLunMap.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/EventAuditLogSubscriber.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/EventMap.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/Image.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/ImageStatus.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/LUN_storage_server_connection_map.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/LdapGroup.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/LdapRefStatus.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/LdapUser.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/MigrateOnErrorOptions.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/Quota.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/QuotaEnforcementTypeEnum.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/QuotaUsagePerUser.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/Role.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/RoleGroupMap.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/RoleType.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/Snapshot.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/SpmStatusResult.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/StorageDomain.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/StorageDomainDynamic.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/StorageDomainStatic.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/StoragePool.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/StoragePoolIsoMap.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/StorageServerConnections.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/StorageType.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/TagsType.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/TagsUserGroupMap.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/TagsUserMap.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/TagsVdsMap.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/TagsVmMap.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/TagsVmPoolMap.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VDS.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VDSDomainsData.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VDSGroup.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VDSNiceType.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VDSStatus.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VDSType.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VM.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VMStatus.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VdcOption.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VdcRole.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VdsDynamic.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VdsSpmStatus.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VdsStatic.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VdsStatistics.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VdsTransparentHugePagesState.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VmBase.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VmDevice.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VmDynamic.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VmPauseStatus.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VmPayload.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VmPool.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VmPoolMap.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VmStatic.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VmStatistics.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VmTemplate.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VmTemplateStatus.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VmType.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VolumeFormat.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VolumeType.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/event_notification_hist.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/event_subscriber.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/gluster/GlusterBrickEntity.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/gluster/GlusterHookEntity.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/gluster/GlusterVolumeEntity.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/image_storage_domain_map.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/network/Network.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/network/NetworkCluster.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/network/VdsInterfaceType.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/network/VmInterfaceType.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/network/VmNetworkInterface.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/network/VmNic.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/permissions.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/tags.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/vds_spm_id_map.java
M backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/job/Job.java
M backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/job/Step.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/job/StepEnum.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/users/VdcUser.java
M
backend/manager/modules/common/src/test/java/org/ovirt/engine/core/common/businessentities/network/VmNetworkInterfaceValidationTest.java
93 files changed, 468 insertions(+), 323 deletions(-)
Approvals:
Allon Mureinik: Verified; Looks good to me, approved
--
To view, visit
http://gerrit.ovirt.org/18133
To unsubscribe, visit
http://gerrit.ovirt.org/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: I8e8eb9ccb0e68db936489110d7f5c5828d07fab4
Gerrit-PatchSet: 3
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Allon Mureinik <amureini(a)redhat.com>
Gerrit-Reviewer: Alexander Wels <awels(a)redhat.com>
Gerrit-Reviewer: Allon Mureinik <amureini(a)redhat.com>
Gerrit-Reviewer: Daniel Erez <derez(a)redhat.com>
Gerrit-Reviewer: Omer Frenkel <ofrenkel(a)redhat.com>
Gerrit-Reviewer: Tal Nisan <tnisan(a)redhat.com>
Gerrit-Reviewer: Vojtech Szocs <vszocs(a)redhat.com>
Gerrit-Reviewer: Yair Zaslavsky <yzaslavs(a)redhat.com>
Gerrit-Reviewer: oVirt Jenkins CI Server