Delete netconf
[controller.git] / opendaylight / netconf / tools / netconf-testtool / src / main / java / org / opendaylight / controller / netconf / test / tool / client / http / perf / SyncExecutionStrategy.java
diff --git a/opendaylight/netconf/tools/netconf-testtool/src/main/java/org/opendaylight/controller/netconf/test/tool/client/http/perf/SyncExecutionStrategy.java b/opendaylight/netconf/tools/netconf-testtool/src/main/java/org/opendaylight/controller/netconf/test/tool/client/http/perf/SyncExecutionStrategy.java
deleted file mode 100644 (file)
index c3d9646..0000000
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * Copyright (c) 2015 Cisco Systems, Inc. and others.  All rights reserved.
- *
- * This program and the accompanying materials are made available under the
- * terms of the Eclipse Public License v1.0 which accompanies this distribution,
- * and is available at http://www.eclipse.org/legal/epl-v10.html
- */
-
-package org.opendaylight.controller.netconf.test.tool.client.http.perf;
-
-import com.ning.http.client.AsyncHttpClient;
-import com.ning.http.client.Request;
-import com.ning.http.client.Response;
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.concurrent.ExecutionException;
-import org.opendaylight.controller.netconf.test.tool.client.stress.ExecutionStrategy;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-public class SyncExecutionStrategy implements ExecutionStrategy{
-
-    private static final Logger LOG = LoggerFactory.getLogger(SyncExecutionStrategy.class);
-
-    private final Parameters params;
-    private final ArrayList<Request> payloads;
-    private final AsyncHttpClient asyncHttpClient;
-
-    SyncExecutionStrategy(final Parameters params, final AsyncHttpClient asyncHttpClient, final ArrayList<Request> payloads) {
-        this.params = params;
-        this.asyncHttpClient = asyncHttpClient;
-        this.payloads = payloads;
-    }
-
-    @Override
-    public void invoke() {
-
-        LOG.info("Begin sending sync requests");
-        for (Request request : payloads) {
-            try {
-                Response response = asyncHttpClient.executeRequest(request).get();
-                if (response.getStatusCode() != 200 && response.getStatusCode() != 204) {
-                    LOG.warn("Status code: {}", response.getStatusCode());
-                    LOG.warn("url: {}", request.getUrl());
-                    LOG.warn(response.getResponseBody());
-                }
-            } catch (InterruptedException | ExecutionException | IOException e) {
-                LOG.warn(e.toString());
-            }
-        }
-        LOG.info("End sending sync requests");
-
-    }
-}