VMware Cloud Community
velezr
Contributor
Contributor
Jump to solution

vRA Cloud Client

I'm trying to cancel some in progress requests and I've been trying to use cloud client:

vra request cancel --id

I'm getting a 404 Error.  This cancel feature is been in place since CC 4.5 I think and I never been able to use it correctly. Is this feature working?

Cloud Client version - 4.7

vRA - 7.3

Logs from cloud client:

org.springframework.web.client.HttpClientErrorException: 404

    at org.springframework.web.client.DefaultResponseErrorHandler.handleError(DefaultResponseErrorHandler.java:94) ~[spring-web-5.0.7.RELEASE.jar:5.0.7.RELEASE]

    at org.springframework.web.client.DefaultResponseErrorHandler.handleError(DefaultResponseErrorHandler.java:79) ~[spring-web-5.0.7.RELEASE.jar:5.0.7.RELEASE]

    at com.vmware.vcac.platform.rest.client.error.ResponseErrorHandler.handleError(ResponseErrorHandler.java:61) ~[cafe-sdk-7.6.0-SNAPSHOT-13027133.jar:?]

    at org.springframework.web.client.ResponseErrorHandler.handleError(ResponseErrorHandler.java:63) ~[spring-web-5.0.7.RELEASE.jar:5.0.7.RELEASE]

    at org.springframework.web.client.RestTemplate.handleResponse(RestTemplate.java:766) ~[spring-web-5.0.7.RELEASE.jar:5.0.7.RELEASE]

    at org.springframework.web.client.RestTemplate.doExecute(RestTemplate.java:724) ~[spring-web-5.0.7.RELEASE.jar:5.0.7.RELEASE]

    at org.springframework.web.client.RestTemplate.execute(RestTemplate.java:698) ~[spring-web-5.0.7.RELEASE.jar:5.0.7.RELEASE]

    at org.springframework.web.client.RestTemplate.postForLocation(RestTemplate.java:423) ~[spring-web-5.0.7.RELEASE.jar:5.0.7.RELEASE]

    at com.vmware.vcac.platform.rest.client.impl.RestClientImpl.post(RestClientImpl.java:372) ~[cafe-sdk-7.6.0-SNAPSHOT-13027133.jar:?]

    at com.vmware.vcac.platform.rest.client.services.AbstractService.post(AbstractService.java:147) ~[cafe-sdk-7.6.0-SNAPSHOT-13027133.jar:?]

    at com.vmware.vcac.catalog.rest.client.service.impl.ConsumerRequestService.cancelRequest(ConsumerRequestService.java:312) ~[cafe-sdk-7.6.0-SNAPSHOT-13027133.jar:?]

    at com.vmware.cloudclient.plugins.utils.CafeEndpointHelper.CancelRequest(CafeEndpointHelper.java:533) ~[core-4.7.0.jar:4.7.0]

    at com.vmware.cloudclient.vcac.service.cafe.RequestService.cancel(RequestService.java:94) ~[plugin-vcac-4.7.0.jar:?]

    at com.vmware.cloudclient.vcac.commands.cafe.RequestCommands.cancelRequest(RequestCommands.java:83) ~[plugin-vcac-4.7.0.jar:?]

    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_201]

    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_201]

    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_201]

    at java.lang.reflect.Method.invoke(Unknown Source) ~[?:1.8.0_201]

    at org.springframework.util.ReflectionUtils.invokeMethod(ReflectionUtils.java:223) ~[spring-core-5.0.7.RELEASE.jar:5.0.7.RELEASE]

    at org.springframework.shell.core.SimpleExecutionStrategy.invoke(SimpleExecutionStrategy.java:68) ~[spring-shell-1.2.0.RELEASE.jar:1.2.0.RELEASE]

    at org.springframework.shell.core.SimpleExecutionStrategy.execute(SimpleExecutionStrategy.java:50) [spring-shell-1.2.0.RELEASE.jar:1.2.0.RELEASE]

    at org.springframework.shell.core.AbstractShell.executeCommand(AbstractShell.java:134) [spring-shell-1.2.0.RELEASE.jar:1.2.0.RELEASE]

    at org.springframework.shell.core.JLineShell.promptLoop(JLineShell.java:533) [spring-shell-1.2.0.RELEASE.jar:1.2.0.RELEASE]

    at org.springframework.shell.core.JLineShell.run(JLineShell.java:179) [spring-shell-1.2.0.RELEASE.jar:1.2.0.RELEASE]

    at java.lang.Thread.run(Unknown Source) [?:1.8.0_201]

2019-07-12 11:42:07,232 cc: [priority="ERROR" thread="Spring Shell"] com.vmware.cloudclient.core.authentication.BaseAuthentication.afterThrowingInvocation:311 - 404

org.springframework.web.client.HttpClientErrorException: 404

    at org.springframework.web.client.DefaultResponseErrorHandler.handleError(DefaultResponseErrorHandler.java:94) ~[spring-web-5.0.7.RELEASE.jar:5.0.7.RELEASE]

    at org.springframework.web.client.DefaultResponseErrorHandler.handleError(DefaultResponseErrorHandler.java:79) ~[spring-web-5.0.7.RELEASE.jar:5.0.7.RELEASE]

    at com.vmware.vcac.platform.rest.client.error.ResponseErrorHandler.handleError(ResponseErrorHandler.java:61) ~[cafe-sdk-7.6.0-SNAPSHOT-13027133.jar:?]

    at org.springframework.web.client.ResponseErrorHandler.handleError(ResponseErrorHandler.java:63) ~[spring-web-5.0.7.RELEASE.jar:5.0.7.RELEASE]

    at org.springframework.web.client.RestTemplate.handleResponse(RestTemplate.java:766) ~[spring-web-5.0.7.RELEASE.jar:5.0.7.RELEASE]

    at org.springframework.web.client.RestTemplate.doExecute(RestTemplate.java:724) ~[spring-web-5.0.7.RELEASE.jar:5.0.7.RELEASE]

    at org.springframework.web.client.RestTemplate.execute(RestTemplate.java:698) ~[spring-web-5.0.7.RELEASE.jar:5.0.7.RELEASE]

    at org.springframework.web.client.RestTemplate.postForLocation(RestTemplate.java:423) ~[spring-web-5.0.7.RELEASE.jar:5.0.7.RELEASE]

    at com.vmware.vcac.platform.rest.client.impl.RestClientImpl.post(RestClientImpl.java:372) ~[cafe-sdk-7.6.0-SNAPSHOT-13027133.jar:?]

    at com.vmware.vcac.platform.rest.client.services.AbstractService.post(AbstractService.java:147) ~[cafe-sdk-7.6.0-SNAPSHOT-13027133.jar:?]

    at com.vmware.vcac.catalog.rest.client.service.impl.ConsumerRequestService.cancelRequest(ConsumerRequestService.java:312) ~[cafe-sdk-7.6.0-SNAPSHOT-13027133.jar:?]

    at com.vmware.cloudclient.plugins.utils.CafeEndpointHelper.CancelRequest(CafeEndpointHelper.java:533) ~[core-4.7.0.jar:4.7.0]

    at com.vmware.cloudclient.vcac.service.cafe.RequestService.cancel(RequestService.java:94) ~[plugin-vcac-4.7.0.jar:?]

    at com.vmware.cloudclient.vcac.commands.cafe.RequestCommands.cancelRequest(RequestCommands.java:83) ~[plugin-vcac-4.7.0.jar:?]

    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_201]

    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_201]

    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_201]

    at java.lang.reflect.Method.invoke(Unknown Source) ~[?:1.8.0_201]

    at org.springframework.util.ReflectionUtils.invokeMethod(ReflectionUtils.java:223) ~[spring-core-5.0.7.RELEASE.jar:5.0.7.RELEASE]

    at org.springframework.shell.core.SimpleExecutionStrategy.invoke(SimpleExecutionStrategy.java:68) ~[spring-shell-1.2.0.RELEASE.jar:1.2.0.RELEASE]

    at org.springframework.shell.core.SimpleExecutionStrategy.execute(SimpleExecutionStrategy.java:50) [spring-shell-1.2.0.RELEASE.jar:1.2.0.RELEASE]

    at org.springframework.shell.core.AbstractShell.executeCommand(AbstractShell.java:134) [spring-shell-1.2.0.RELEASE.jar:1.2.0.RELEASE]

    at org.springframework.shell.core.JLineShell.promptLoop(JLineShell.java:533) [spring-shell-1.2.0.RELEASE.jar:1.2.0.RELEASE]

    at org.springframework.shell.core.JLineShell.run(JLineShell.java:179) [spring-shell-1.2.0.RELEASE.jar:1.2.0.RELEASE]

    at java.lang.Thread.run(Unknown Source) [?:1.8.0_201

0 Kudos
1 Solution

Accepted Solutions
daphnissov
Immortal
Immortal
Jump to solution

I just had a look. Canceling requests only came out in vRA 7.4. You're getting the 404 error because that API doesn't exist in 7.3, and CC is just a CLI tool for the API.

---------------------------------------------------------------------------------------------------------

Was it helpful? Let us know by completing this short survey here.

View solution in original post

0 Kudos
3 Replies
daphnissov
Immortal
Immortal
Jump to solution

Use the version of Cloud Client appropriate to your 7.3 release. Sometimes later releases of CC don't work well with earlier-than-intended releases of vRA.

0 Kudos
velezr
Contributor
Contributor
Jump to solution

Thanks for your help, If I saw the version and support correctly then Cloud Client 4.3 supports 7.3, this version doesn't have request cancel it seems. So the only way to clean this is to update the DB manually.

0 Kudos
daphnissov
Immortal
Immortal
Jump to solution

I just had a look. Canceling requests only came out in vRA 7.4. You're getting the 404 error because that API doesn't exist in 7.3, and CC is just a CLI tool for the API.

---------------------------------------------------------------------------------------------------------

Was it helpful? Let us know by completing this short survey here.

0 Kudos