Yair Zaslavsky has posted comments on this change.

Change subject: engine: Retrieve errata from satellite/katello
......................................................................


Patch Set 4:

(3 comments)

http://gerrit.ovirt.org/#/c/37434/4/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/host/provider/foreman/ForemanHostProviderProxy.java
File 
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/host/provider/foreman/ForemanHostProviderProxy.java:

Line 50: 
Line 51:     private static final String OPERATION_SYSTEM_ENTRY_POINT = 
API_ENTRY_POINT + "/operatingsystems";
Line 52:     private static final String OPERATION_SYSTEM_QUERY = 
OPERATION_SYSTEM_ENTRY_POINT + "?" + JSON_FORMAT;
Line 53: 
Line 54:     private static final String KATELLO_API_ENTRY_POINT = 
"/katello/api/v2";
> There is no katello without foreman.
ok
Line 55:     private static final String CONTENT_HOSTS_ENTRY_POINT = 
KATELLO_API_ENTRY_POINT + "/systems";
Line 56:     private static final String CONTENT_HOST_ERRATA_ENTRY_POINT = 
CONTENT_HOSTS_ENTRY_POINT + "/%1$s/errata";
Line 57:     private static final String CONTENT_HOST_ERRATUM_ENTRY_POINT = 
CONTENT_HOSTS_ENTRY_POINT + "/%1$s/errata/%2$s";
Line 58: 


Line 331: 
Line 332:         return latestRegisteredHost;
Line 333:     }
Line 334: 
Line 335:     private List<ContentHost> runContentHostListMethod(String 
relativeUrl) {
This is used only once in the code, do we really need it? why not have its code 
in findContentHost?
Line 336:         try {
Line 337:             ContentHostsWrapper wrapper =
Line 338:                     
objectMapper.readValue(runHttpGetMethod(relativeUrl), 
ContentHostsWrapper.class);
Line 339:             return Arrays.asList(wrapper.getResults());


Line 381:         if (contentHost == null) {
Line 382:             return Collections.emptyList();
Line 383:         }
Line 384: 
Line 385:         return 
runErrataListMethod(String.format(CONTENT_HOST_ERRATA_ENTRY_POINT, 
contentHost.getId()));
and on the other hand you have here and in the next method some code 
duplication.
Line 386:     }
Line 387: 
Line 388:     @Override
Line 389:     public Erratum getErratumForHost(VdsStatic host, String 
erratumId) {


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

Gerrit-MessageType: comment
Gerrit-Change-Id: I0d2b79d731dcd605aa567e544d09b56090174756
Gerrit-PatchSet: 4
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Moti Asayag <masa...@redhat.com>
Gerrit-Reviewer: Moti Asayag <masa...@redhat.com>
Gerrit-Reviewer: Oved Ourfali <oourf...@redhat.com>
Gerrit-Reviewer: Yair Zaslavsky <yzasl...@redhat.com>
Gerrit-Reviewer: automat...@ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
_______________________________________________
Engine-patches mailing list
Engine-patches@ovirt.org
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to