From: Robert Varga Date: Tue, 3 Nov 2020 13:45:09 +0000 (+0100) Subject: Correct operations input/output media types X-Git-Tag: release/magnesium-sr3~2 X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=commitdiff_plain;h=refs%2Fchanges%2F22%2F93522%2F1;p=netconf.git Correct operations input/output media types We do not produce/consume raw yang-data, add the missing XML qualifier. JIRA: NETCONF-741 Change-Id: I2978527125c80ae142af1f0b307c3b99adbe3ba9 Signed-off-by: Robert Varga (cherry picked from commit f679d21f00818505ec5b5299c4ffce7dea9263f4) --- diff --git a/restconf/restconf-nb-rfc8040/src/main/java/org/opendaylight/restconf/nb/rfc8040/rests/services/api/RestconfInvokeOperationsService.java b/restconf/restconf-nb-rfc8040/src/main/java/org/opendaylight/restconf/nb/rfc8040/rests/services/api/RestconfInvokeOperationsService.java index faa0a4a1e7..dd9f2f515e 100644 --- a/restconf/restconf-nb-rfc8040/src/main/java/org/opendaylight/restconf/nb/rfc8040/rests/services/api/RestconfInvokeOperationsService.java +++ b/restconf/restconf-nb-rfc8040/src/main/java/org/opendaylight/restconf/nb/rfc8040/rests/services/api/RestconfInvokeOperationsService.java @@ -42,10 +42,10 @@ public interface RestconfInvokeOperationsService extends UpdateHandlers { */ @POST @Path("/operations/{identifier:.+}") - @Produces({ Rfc8040.MediaTypes.DATA + RestconfConstants.JSON, Rfc8040.MediaTypes.DATA, MediaType.APPLICATION_JSON, - MediaType.APPLICATION_XML, MediaType.TEXT_XML }) - @Consumes({ Rfc8040.MediaTypes.DATA + RestconfConstants.JSON, Rfc8040.MediaTypes.DATA, MediaType.APPLICATION_JSON, - MediaType.APPLICATION_XML, MediaType.TEXT_XML }) + @Produces({ Rfc8040.MediaTypes.DATA + RestconfConstants.JSON, Rfc8040.MediaTypes.DATA + RestconfConstants.XML, + MediaType.APPLICATION_JSON, MediaType.APPLICATION_XML, MediaType.TEXT_XML }) + @Consumes({ Rfc8040.MediaTypes.DATA + RestconfConstants.JSON, Rfc8040.MediaTypes.DATA + RestconfConstants.XML, + MediaType.APPLICATION_JSON, MediaType.APPLICATION_XML, MediaType.TEXT_XML }) NormalizedNodeContext invokeRpc(@Encoded @PathParam("identifier") String identifier, NormalizedNodeContext payload, @Context UriInfo uriInfo); }