mirror of https://github.com/apache/jclouds.git
fix cloneMedia (bad path) and deleteMedia (wrong ID)
This commit is contained in:
parent
0f5cae3eaf
commit
f0913ee6b4
|
@ -78,11 +78,12 @@ public interface MediaAsyncClient {
|
|||
* @see MediaClient#cloneMedia(URI, CloneMediaParams)
|
||||
*/
|
||||
@POST
|
||||
@Path("/action/cloneMedia")
|
||||
@Consumes(VCloudDirectorMediaType.MEDIA)
|
||||
@Produces(VCloudDirectorMediaType.CLONE_MEDIA_PARAMS)
|
||||
@JAXBResponseParser
|
||||
@ExceptionParser(ThrowVCloudErrorOn4xx.class)
|
||||
ListenableFuture<Media> cloneMedia(@EndpointParam URI cloneLink,
|
||||
ListenableFuture<Media> cloneMedia(@EndpointParam URI vdcRef,
|
||||
@BinderParam(BindToXMLPayload.class) CloneMediaParams params);
|
||||
|
||||
/**
|
||||
|
|
|
@ -398,7 +398,7 @@ public class MediaClientLiveTest extends BaseVCloudDirectorClientLiveTest {
|
|||
Error expected = Error.builder()
|
||||
.message(String.format(
|
||||
"No access to entity \"(com.vmware.vcloud.entity.media:%s)\".",
|
||||
media.getId()))
|
||||
media.getId().substring("urn:vcloud:media:".length())))
|
||||
.majorErrorCode(403)
|
||||
.minorErrorCode("ACCESS_TO_RESOURCE_IS_FORBIDDEN")
|
||||
.build();
|
||||
|
|
Loading…
Reference in New Issue