From 26646872d5edb1d254608d76773990d954ae0cfb Mon Sep 17 00:00:00 2001 From: Andrew Donald Kennedy Date: Wed, 21 Mar 2012 14:00:32 +0000 Subject: [PATCH] Issue 830: Fix HTTP method for answerQuestion operation --- .../jclouds/vcloud/director/v1_5/features/VAppAsyncClient.java | 2 +- .../org/jclouds/vcloud/director/v1_5/features/VAppClient.java | 2 +- .../vcloud/director/v1_5/features/VAppClientLiveTest.java | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/labs/vcloud-director/src/main/java/org/jclouds/vcloud/director/v1_5/features/VAppAsyncClient.java b/labs/vcloud-director/src/main/java/org/jclouds/vcloud/director/v1_5/features/VAppAsyncClient.java index 557e16d681..1d962b1b3f 100644 --- a/labs/vcloud-director/src/main/java/org/jclouds/vcloud/director/v1_5/features/VAppAsyncClient.java +++ b/labs/vcloud-director/src/main/java/org/jclouds/vcloud/director/v1_5/features/VAppAsyncClient.java @@ -515,7 +515,7 @@ public interface VAppAsyncClient { /** * @see VAppClient#answerQuestion(URI, VmQuestionAnswer) */ - @PUT + @POST @Path("/question/action/answer") @Produces(VM_PENDING_ANSWER) @Consumes diff --git a/labs/vcloud-director/src/main/java/org/jclouds/vcloud/director/v1_5/features/VAppClient.java b/labs/vcloud-director/src/main/java/org/jclouds/vcloud/director/v1_5/features/VAppClient.java index 6d82c60722..2509e2f5df 100644 --- a/labs/vcloud-director/src/main/java/org/jclouds/vcloud/director/v1_5/features/VAppClient.java +++ b/labs/vcloud-director/src/main/java/org/jclouds/vcloud/director/v1_5/features/VAppClient.java @@ -574,7 +574,7 @@ public interface VAppClient { * The answer IDs of choice and question should match the ones returned from operation {@link #getPendingQuestion(URI)}. * *
-    * PUT /vApp/{id}/question/action/answer
+    * POST /vApp/{id}/question/action/answer
     * 
* * @since 0.9 diff --git a/labs/vcloud-director/src/test/java/org/jclouds/vcloud/director/v1_5/features/VAppClientLiveTest.java b/labs/vcloud-director/src/test/java/org/jclouds/vcloud/director/v1_5/features/VAppClientLiveTest.java index dde23e3371..2458f0c7b0 100644 --- a/labs/vcloud-director/src/test/java/org/jclouds/vcloud/director/v1_5/features/VAppClientLiveTest.java +++ b/labs/vcloud-director/src/test/java/org/jclouds/vcloud/director/v1_5/features/VAppClientLiveTest.java @@ -786,7 +786,7 @@ public class VAppClientLiveTest extends AbstractVAppClientLiveTest { checkVmPendingQuestion(question); } - @Test(testName = "PUT /vApp/{id}/question/action/answer", dependsOnMethods = { "testGetPendingQuestion" }) + @Test(testName = "POST /vApp/{id}/question/action/answer", dependsOnMethods = { "testGetPendingQuestion" }) public void testAnswerQuestion() { // TODO check that the question has been answered (e.g. asking for getPendingQuestion does not // include our answered question).