Alon Bar-Lev has posted comments on this change.

Change subject: core: remove commons httpclient from provider proxy
......................................................................


Patch Set 18:

(3 comments)

http://gerrit.ovirt.org/#/c/33458/18/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 291:     @Override
Line 292:     public void onRemoval() {
Line 293:     }
Line 294: 
Line 295:     private void runHttpModificatioMethod(HttpMethodType httpMethod, 
String relativeUrl, String body) {
not sure why we cannot have in base doHttp() to receive method, input, output 
and if input is non null not perform input. otherwise we have duplication.
Line 296:         HttpURLConnection connection = createConnection(relativeUrl);
Line 297:         try {
Line 298:             connection.setRequestProperty("Content-Type", 
"application/json; charset=utf-8");
Line 299:             connection.setDoOutput(true);


http://gerrit.ovirt.org/#/c/33458/18/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/provider/BaseProviderProxy.java
File 
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/provider/BaseProviderProxy.java:

Line 49:         List<? extends Certificate> result = null;
Line 50:         if 
(url.getProtocol().equalsIgnoreCase(String.valueOf("https"))) {
Line 51:             HttpURLConnection conn = null;
Line 52:             try {
Line 53:                 conn = new 
HttpURLConnectionBuilder(url).setVerifyChain(false).create();
you can have the new above and in finally only disconnect.
Line 54:                 result = Arrays.asList(((HttpsURLConnection) 
conn).getServerCertificates());
Line 55:             } catch (CertificateException | NoSuchAlgorithmException | 
InvalidKeyException | NoSuchProviderException
Line 56:                     | SignatureException | SSLHandshakeException ex) {
Line 57:             } catch (IOException | GeneralSecurityException e) {


Line 106:                                             
.getBytes(Charset.forName("UTF-8")))
Line 107:                             )
Line 108:                             .toString());
Line 109:         }
Line 110:     }
here we should also have the doHttpRequestResponse... removed from foreman.
Line 111: 


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

Gerrit-MessageType: comment
Gerrit-Change-Id: I727d34c33f357b93560d4b5a1784b3733b7fa293
Gerrit-PatchSet: 18
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Yair Zaslavsky <[email protected]>
Gerrit-Reviewer: Alon Bar-Lev <[email protected]>
Gerrit-Reviewer: Moti Asayag <[email protected]>
Gerrit-Reviewer: Oved Ourfali <[email protected]>
Gerrit-Reviewer: Yair Zaslavsky <[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