This is an automated email from the ASF dual-hosted git repository.
exceptionfactory pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/nifi.git
The following commit(s) were added to refs/heads/main by this push:
new 936985021b3 NIFI-15662 Fixed several Swagger Annotations for REST API
(#10957)
936985021b3 is described below
commit 936985021b32860ef441c3c750468e2f20783561
Author: Michael Moser <[email protected]>
AuthorDate: Tue Mar 10 16:40:50 2026 -0400
NIFI-15662 Fixed several Swagger Annotations for REST API (#10957)
Signed-off-by: David Handermann <[email protected]>
---
.../nifi/web/api/AuthenticationResource.java | 2 +-
.../apache/nifi/web/api/ControllerResource.java | 18 +++++------
.../apache/nifi/web/api/DataTransferResource.java | 28 ++++++++++++++++
.../java/org/apache/nifi/web/api/FlowResource.java | 15 ++++++---
.../nifi/web/api/ParameterContextResource.java | 5 +--
.../nifi/web/api/ParameterProviderResource.java | 1 +
.../apache/nifi/web/api/ProcessGroupResource.java | 34 +++++++++++++-------
.../apache/nifi/web/api/ProvenanceResource.java | 6 ++--
.../nifi/web/api/RemoteProcessGroupResource.java | 18 +++++------
.../nifi/web/api/SystemDiagnosticsResource.java | 2 +-
.../org/apache/nifi/web/api/VersionsResource.java | 37 ++++++++++++++--------
11 files changed, 108 insertions(+), 58 deletions(-)
diff --git
a/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/AuthenticationResource.java
b/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/AuthenticationResource.java
index 1ceb2a8da9f..16a00758a27 100644
---
a/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/AuthenticationResource.java
+++
b/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/AuthenticationResource.java
@@ -68,7 +68,7 @@ public class AuthenticationResource extends
ApplicationResource {
@Produces(MediaType.APPLICATION_JSON)
@Path("/configuration")
@Operation(
- summary = "Retrieves the authentication configuration endpoint and
status information",
+ summary = "Retrieves the authentication configuration details and
status information",
responses = @ApiResponse(content = @Content(schema =
@Schema(implementation = AuthenticationConfigurationEntity.class)))
)
@SecurityRequirements
diff --git
a/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/ControllerResource.java
b/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/ControllerResource.java
index fc18ed39997..4fb23033296 100644
---
a/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/ControllerResource.java
+++
b/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/ControllerResource.java
@@ -214,7 +214,7 @@ public class ControllerResource extends ApplicationResource
{
@Produces(MediaType.APPLICATION_JSON)
@Path("config")
@Operation(
- summary = "Retrieves the configuration for this NiFi",
+ summary = "Updates the configuration for this NiFi",
responses = {
@ApiResponse(responseCode = "200", content =
@Content(schema = @Schema(implementation =
ControllerConfigurationEntity.class))),
@ApiResponse(responseCode = "400", description = "NiFi was
unable to complete the request because it was invalid. The request should not
be retried without modification."),
@@ -2283,7 +2283,7 @@ public class ControllerResource extends
ApplicationResource {
@Produces(MediaType.APPLICATION_JSON)
@Path("registry-types")
@Operation(
- summary = "Retrieves the types of flow that this NiFi supports",
+ summary = "Retrieves the types of flow registry clients that this
NiFi supports",
description = NON_GUARANTEED_ENDPOINT,
responses = {
@ApiResponse(responseCode = "200", content =
@Content(schema = @Schema(implementation =
FlowRegistryClientTypesEntity.class))),
@@ -2938,9 +2938,8 @@ public class ControllerResource extends
ApplicationResource {
}
)
public Response getNarSummary(
- @PathParam("id")
@Parameter(description = "The id of the NAR.", required = true)
- final String id) {
+ @PathParam("id") final String id) {
authorizeController(RequestAction.READ);
if (StringUtils.isBlank(id)) {
@@ -2973,9 +2972,8 @@ public class ControllerResource extends
ApplicationResource {
}
)
public Response getNarDetails(
- @PathParam("id")
@Parameter(description = "The id of the NAR.", required = true)
- final String id) {
+ @PathParam("id") final String id) {
authorizeController(RequestAction.READ);
if (StringUtils.isBlank(id)) {
@@ -3008,9 +3006,8 @@ public class ControllerResource extends
ApplicationResource {
}
)
public Response downloadNar(
- @PathParam("id")
@Parameter(description = "The id of the NAR.", required = true)
- final String id) {
+ @PathParam("id") final String id) {
authorizeController(RequestAction.READ);
if (StringUtils.isBlank(id)) {
@@ -3052,13 +3049,14 @@ public class ControllerResource extends
ApplicationResource {
}
)
public Response deleteNar(
+ @Parameter(description = "Acknowledges that this node is
disconnected to allow for mutable requests to proceed.")
@QueryParam(DISCONNECTED_NODE_ACKNOWLEDGED) @DefaultValue("false")
final Boolean disconnectedNodeAcknowledged,
+ @Parameter(description = "Indicates if the NAR should be deleted
even when components are instantiated.")
@QueryParam("force") @DefaultValue("false")
final Boolean forceDelete,
- @PathParam("id")
@Parameter(description = "The id of the NAR.", required = true)
- final String id) throws IOException {
+ @PathParam("id") final String id) throws IOException {
if (StringUtils.isBlank(id)) {
throw new IllegalArgumentException("Id is required");
diff --git
a/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/DataTransferResource.java
b/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/DataTransferResource.java
index ea47935f580..aa2eb34e3f8 100644
---
a/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/DataTransferResource.java
+++
b/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/DataTransferResource.java
@@ -173,6 +173,10 @@ public class DataTransferResource extends
ApplicationResource {
required = true
)
@PathParam("portType") String portType,
+ @Parameter(
+ description = "The input or output port id.",
+ required = true
+ )
@PathParam("portId") String portId,
@Context HttpServletRequest req,
@Context ServletContext context,
@@ -243,6 +247,10 @@ public class DataTransferResource extends
ApplicationResource {
required = true
)
@PathParam("portId") String portId,
+ @Parameter(
+ description = "The transaction id.",
+ required = true
+ )
@PathParam("transactionId") String transactionId,
@Context HttpServletRequest req,
@Context ServletContext context,
@@ -615,6 +623,10 @@ public class DataTransferResource extends
ApplicationResource {
required = true
)
@PathParam("portId") String portId,
+ @Parameter(
+ description = "The transaction id.",
+ required = true
+ )
@PathParam("transactionId") String transactionId,
@Context HttpServletRequest req,
@Context HttpServletResponse res,
@@ -688,7 +700,15 @@ public class DataTransferResource extends
ApplicationResource {
}
)
public Response extendInputPortTransactionTTL(
+ @Parameter(
+ description = "The input port id.",
+ required = true
+ )
@PathParam("portId") String portId,
+ @Parameter(
+ description = "The transaction id.",
+ required = true
+ )
@PathParam("transactionId") String transactionId,
@Context HttpServletRequest req,
@Context HttpServletResponse res,
@@ -724,7 +744,15 @@ public class DataTransferResource extends
ApplicationResource {
}
)
public Response extendOutputPortTransactionTTL(
+ @Parameter(
+ description = "The output port id.",
+ required = true
+ )
@PathParam("portId") String portId,
+ @Parameter(
+ description = "The transaction id.",
+ required = true
+ )
@PathParam("transactionId") String transactionId,
@Context HttpServletRequest req,
@Context HttpServletResponse res,
diff --git
a/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/FlowResource.java
b/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/FlowResource.java
index d94f8b05a4e..eef02501335 100644
---
a/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/FlowResource.java
+++
b/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/FlowResource.java
@@ -640,9 +640,12 @@ public class FlowResource extends ApplicationResource {
"such, " +
"the selected fields may change at any time, even during
incremental releases, without warning. As a result, this parameter should not
be provided by any client other than the UI."
)
- public Response getControllerServicesFromController(@QueryParam("uiOnly")
@DefaultValue("false") final boolean uiOnly,
-
@QueryParam("includeReferencingComponents") @DefaultValue("true")
- @Parameter(description
= "Whether or not to include services' referencing components in the response")
boolean includeReferences) {
+ public Response getControllerServicesFromController(
+ @Parameter(description = "Whether or not to include services'
referencing components in the response")
+ @QueryParam("includeReferencingComponents") @DefaultValue("true")
+ boolean includeReferences,
+ @QueryParam("uiOnly") @DefaultValue("false")
+ final boolean uiOnly) {
authorizeFlow();
@@ -1131,7 +1134,7 @@ public class FlowResource extends ApplicationResource {
public Response activateControllerServices(
@Parameter(description = "The process group id.", required = true)
@PathParam("id") String id,
- @Parameter(description = "The request to schedule or unschedule.
If the comopnents in the request are not specified, all authorized components
will be considered.", required = true)
+ @Parameter(description = "The request to schedule or unschedule.
If the components in the request are not specified, all authorized components
will be considered.", required = true)
final ActivateControllerServicesEntity requestEntity) {
if (requestEntity == null) {
@@ -1427,7 +1430,9 @@ public class FlowResource extends ApplicationResource {
}
)
public Response searchFlow(
+ @Parameter(description = "The search term.")
@QueryParam("q") @DefaultValue(StringUtils.EMPTY) String value,
+ @Parameter(description = "The id of the currently visited process
group. If not specified, then the root process group is used.")
@QueryParam("a") @DefaultValue(StringUtils.EMPTY) String
activeGroupId
) {
authorizeFlow();
@@ -2897,7 +2902,7 @@ public class FlowResource extends ApplicationResource {
)
@QueryParam("groupId") BulletinBoardPatternParameter groupId,
@Parameter(
- description = "The number of bulletins to limit the
response to."
+ description = "The number of bulletins to limit the
response to. Optional, default is no limit."
)
@QueryParam("limit") IntegerParameter limit) throws
InterruptedException {
diff --git
a/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/ParameterContextResource.java
b/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/ParameterContextResource.java
index 51ece06c1f5..f8d7b3f2906 100644
---
a/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/ParameterContextResource.java
+++
b/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/ParameterContextResource.java
@@ -469,7 +469,7 @@ public class ParameterContextResource extends
AbstractParameterResource {
@Produces(MediaType.APPLICATION_JSON)
@Path("{contextId}/assets")
@Operation(
- summary = "Lists the assets that belong to the Parameter Context
with the given ID",
+ summary = "Lists the assets that belong to the Parameter Context
with the given ID.",
responses = {
@ApiResponse(responseCode = "200", content =
@Content(schema = @Schema(implementation = AssetsEntity.class))),
@ApiResponse(responseCode = "400", description = "NiFi was
unable to complete the request because it was invalid. The request should not
be retried without modification."),
@@ -478,7 +478,6 @@ public class ParameterContextResource extends
AbstractParameterResource {
@ApiResponse(responseCode = "404", description = "The
specified resource could not be found."),
@ApiResponse(responseCode = "409", description = "The
request was valid but NiFi was not in the appropriate state to process it.")
},
- description = "Lists the assets that belong to the Parameter
Context with the given ID.",
security = {
@SecurityRequirement(name = "Read -
/parameter-contexts/{id}")
}
@@ -581,6 +580,7 @@ public class ParameterContextResource extends
AbstractParameterResource {
}
)
public Response deleteAsset(
+ @Parameter(description = "Acknowledges that this node is
disconnected to allow for mutable requests to proceed.")
@QueryParam(DISCONNECTED_NODE_ACKNOWLEDGED) @DefaultValue("false")
final Boolean disconnectedNodeAcknowledged,
@Parameter(description = "The ID of the Parameter Context")
@@ -1015,6 +1015,7 @@ public class ParameterContextResource extends
AbstractParameterResource {
}
)
public Response submitValidationRequest(
+ @Parameter(description = "The ID of the ParameterContext")
@PathParam("contextId") final String contextId,
@Parameter(description = "The validation request", required =
true) final ParameterContextValidationRequestEntity requestEntity) {
diff --git
a/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/ParameterProviderResource.java
b/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/ParameterProviderResource.java
index ffc3082dfe0..23e209d5065 100644
---
a/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/ParameterProviderResource.java
+++
b/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/ParameterProviderResource.java
@@ -918,6 +918,7 @@ public class ParameterProviderResource extends
AbstractParameterResource {
}
)
public Response submitApplyParameters(
+ @Parameter(description = "The ID of the Parameter Provider")
@PathParam("providerId") final String parameterProviderId,
@Parameter(description = "The apply parameters request.", required
= true) final ParameterProviderParameterApplicationEntity requestEntity) {
diff --git
a/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/ProcessGroupResource.java
b/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/ProcessGroupResource.java
index 6d55f9d0651..85fd97533b8 100644
---
a/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/ProcessGroupResource.java
+++
b/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/ProcessGroupResource.java
@@ -30,6 +30,7 @@ import io.swagger.v3.oas.annotations.tags.Tag;
import jakarta.ws.rs.Consumes;
import jakarta.ws.rs.DELETE;
import jakarta.ws.rs.DefaultValue;
+import jakarta.ws.rs.FormParam;
import jakarta.ws.rs.GET;
import jakarta.ws.rs.HttpMethod;
import jakarta.ws.rs.POST;
@@ -129,7 +130,6 @@ import
org.apache.nifi.web.api.entity.RemoteProcessGroupsEntity;
import org.apache.nifi.web.api.request.ClientIdParameter;
import org.apache.nifi.web.api.request.LongParameter;
import org.apache.nifi.web.util.ParameterContextReplacer;
-import org.glassfish.jersey.media.multipart.FormDataParam;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
@@ -2583,8 +2583,12 @@ public class ProcessGroupResource extends
FlowUpdateResource<ProcessGroupImportE
@SecurityRequirement(name = "Read -
/parameter-contexts/{uuid} - For any Parameter Context that is referenced by a
Property that is changed, added, or removed")
}
)
- public Response initiateReplaceProcessGroup(@Parameter(description = "The
process group id.", required = true) @PathParam("id") final String groupId,
- @Parameter(description = "The
process group replace request entity", required = true) final
ProcessGroupImportEntity importEntity) {
+ public Response initiateReplaceProcessGroup(
+ @Parameter(description = "The process group id.", required = true)
+ @PathParam("id") final String groupId,
+ @Parameter(description = "The process group replace request
entity", required = true)
+ final ProcessGroupImportEntity importEntity
+ ) {
if (importEntity == null) {
throw new IllegalArgumentException("Process Group Import Entity is
required");
}
@@ -2658,25 +2662,26 @@ public class ProcessGroupResource extends
FlowUpdateResource<ProcessGroupImportE
description = "The process group name.",
required = true
)
- @FormDataParam("groupName") final String groupName,
+ @FormParam("groupName") final String groupName,
@Parameter(
description = "The process group X position.",
required = true
)
- @FormDataParam("positionX") final Double positionX,
+ @FormParam("positionX") final Double positionX,
@Parameter(
description = "The process group Y position.",
required = true
)
- @FormDataParam("positionY") final Double positionY,
+ @FormParam("positionY") final Double positionY,
@Parameter(
description = "The client id.",
required = true
)
- @FormDataParam("clientId") final String clientId,
+ @FormParam("clientId") final String clientId,
@Parameter(description = "Acknowledges that this node is
disconnected to allow for mutable requests to proceed.")
- @FormDataParam(DISCONNECTED_NODE_ACKNOWLEDGED)
@DefaultValue("false") final Boolean disconnectedNodeAcknowledged,
- @FormDataParam("file") final InputStream in) throws
InterruptedException {
+ @FormParam(DISCONNECTED_NODE_ACKNOWLEDGED) @DefaultValue("false")
final Boolean disconnectedNodeAcknowledged,
+ @Parameter(description = "The flow definition content")
+ @FormParam("file") final InputStream in) throws
InterruptedException {
// ensure the group name is specified
if (StringUtils.isBlank(groupName)) {
@@ -2800,6 +2805,7 @@ public class ProcessGroupResource extends
FlowUpdateResource<ProcessGroupImportE
required = true
)
@PathParam("id") final String groupId,
+ @Parameter(description = "The Process Group Upload import details")
final ProcessGroupUploadEntity processGroupUploadEntity) {
// verify the process group was specified
@@ -3247,8 +3253,12 @@ public class ProcessGroupResource extends
FlowUpdateResource<ProcessGroupImportE
@SecurityRequirement(name = "Write -
/process-groups/{uuid}")
}
)
- public Response replaceProcessGroup(@Parameter(description = "The process
group id.", required = true) @PathParam("id") final String groupId,
- @Parameter(description = "The process
group replace request entity.", required = true) final ProcessGroupImportEntity
importEntity) {
+ public Response replaceProcessGroup(
+ @Parameter(description = "The process group id.", required = true)
+ @PathParam("id") final String groupId,
+ @Parameter(description = "The process group replace request
entity.", required = true)
+ final ProcessGroupImportEntity importEntity
+ ) {
// Verify the request
if (importEntity == null) {
throw new IllegalArgumentException("Process Group Import Entity is
required");
@@ -3364,7 +3374,7 @@ public class ProcessGroupResource extends
FlowUpdateResource<ProcessGroupImportE
@Parameter(description = "The ID of the Update Request")
@PathParam("id") final String replaceRequestId
) {
- return deleteFlowUpdateRequest("replace-requests", replaceRequestId,
disconnectedNodeAcknowledged.booleanValue());
+ return deleteFlowUpdateRequest("replace-requests", replaceRequestId,
disconnectedNodeAcknowledged);
}
/**
diff --git
a/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/ProvenanceResource.java
b/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/ProvenanceResource.java
index 00431a2632c..5434459732a 100644
---
a/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/ProvenanceResource.java
+++
b/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/ProvenanceResource.java
@@ -265,12 +265,12 @@ public class ProvenanceResource extends
ApplicationResource {
)
@QueryParam("clusterNodeId") final String clusterNodeId,
@Parameter(
- description = "Whether or not incremental results are
returned. If false, provenance events"
- + " are only returned once the query completes.
This property is true by default."
+ description = "Whether or not to summarize provenance
events returned. This property is false by default."
)
@QueryParam("summarize") @DefaultValue(value = "false") final
Boolean summarize,
@Parameter(
- description = "Whether or not to summarize provenance
events returned. This property is false by default."
+ description = "Whether or not incremental results are
returned. If false, provenance events"
+ + " are only returned once the query completes.
This property is true by default."
)
@QueryParam("incrementalResults") @DefaultValue(value = "true")
final Boolean incrementalResults,
@Parameter(
diff --git
a/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/RemoteProcessGroupResource.java
b/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/RemoteProcessGroupResource.java
index 9dabe6b8bd9..fb11209606d 100644
---
a/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/RemoteProcessGroupResource.java
+++
b/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/RemoteProcessGroupResource.java
@@ -339,7 +339,7 @@ public class RemoteProcessGroupResource extends
ApplicationResource {
)
@PathParam("port-id") final String portId,
@Parameter(
- description = "The remote process group port.",
+ description = "The remote process group port configuration
details.",
required = true
) final RemoteProcessGroupPortEntity
requestRemoteProcessGroupPortEntity) {
@@ -438,7 +438,7 @@ public class RemoteProcessGroupResource extends
ApplicationResource {
)
@PathParam("port-id") String portId,
@Parameter(
- description = "The remote process group port.",
+ description = "The remote process group port configuration
details.",
required = true
) RemoteProcessGroupPortEntity
requestRemoteProcessGroupPortEntity) {
@@ -512,7 +512,7 @@ public class RemoteProcessGroupResource extends
ApplicationResource {
@Produces(MediaType.APPLICATION_JSON)
@Path("{id}/input-ports/{port-id}/run-status")
@Operation(
- summary = "Updates run status of a remote port",
+ summary = "Updates run status of a remote input port",
description = NON_GUARANTEED_ENDPOINT,
responses = {
@ApiResponse(responseCode = "200", content =
@Content(schema = @Schema(implementation =
RemoteProcessGroupPortEntity.class))),
@@ -538,7 +538,7 @@ public class RemoteProcessGroupResource extends
ApplicationResource {
)
@PathParam("port-id") final String portId,
@Parameter(
- description = "The remote process group port.",
+ description = "The remote process group port run status
details.",
required = true
) final RemotePortRunStatusEntity
requestRemotePortRunStatusEntity) {
@@ -607,7 +607,7 @@ public class RemoteProcessGroupResource extends
ApplicationResource {
@Produces(MediaType.APPLICATION_JSON)
@Path("{id}/output-ports/{port-id}/run-status")
@Operation(
- summary = "Updates run status of a remote port",
+ summary = "Updates run status of a remote output port",
description = NON_GUARANTEED_ENDPOINT,
responses = {
@ApiResponse(responseCode = "200", content =
@Content(schema = @Schema(implementation =
RemoteProcessGroupPortEntity.class))),
@@ -633,7 +633,7 @@ public class RemoteProcessGroupResource extends
ApplicationResource {
)
@PathParam("port-id") String portId,
@Parameter(
- description = "The remote process group port.",
+ description = "The remote process group port run status
details.",
required = true
) RemotePortRunStatusEntity requestRemotePortRunStatusEntity) {
@@ -714,7 +714,7 @@ public class RemoteProcessGroupResource extends
ApplicationResource {
)
@PathParam("id") String id,
@Parameter(
- description = "The remote process group.",
+ description = "The remote process group configuration
details.",
required = true
) final RemoteProcessGroupEntity requestRemoteProcessGroupEntity) {
@@ -958,9 +958,7 @@ public class RemoteProcessGroupResource extends
ApplicationResource {
RemoteProcessGroupsEntity remoteProcessGroupsEntity = new
RemoteProcessGroupsEntity();
- Response response =
generateOkResponse(remoteProcessGroupsEntity).build();
-
- return response;
+ return
generateOkResponse(remoteProcessGroupsEntity).build();
}
);
}
diff --git
a/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/SystemDiagnosticsResource.java
b/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/SystemDiagnosticsResource.java
index 11becd29fcc..be53d84d4fe 100644
---
a/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/SystemDiagnosticsResource.java
+++
b/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/SystemDiagnosticsResource.java
@@ -93,7 +93,7 @@ public class SystemDiagnosticsResource extends
ApplicationResource {
)
@QueryParam("nodewise") @DefaultValue(NODEWISE) final Boolean
nodewise,
@Parameter(
- description = "Whether or not to include verbose details.
Optional, defaults to false"
+ description = "BASIC or VERBOSE verbosity details.
Optional, defaults to BASIC"
)
@QueryParam("diagnosticLevel") @DefaultValue("BASIC") final
DiagnosticLevel diagnosticLevel,
@Parameter(
diff --git
a/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/VersionsResource.java
b/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/VersionsResource.java
index 3026c6b1394..acf2f05102b 100644
---
a/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/VersionsResource.java
+++
b/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/VersionsResource.java
@@ -120,7 +120,8 @@ public class VersionsResource extends
FlowUpdateResource<VersionControlInformati
@SecurityRequirement(name = "Read -
/process-groups/{uuid}")
}
)
- public Response getVersionInformation(@Parameter(description = "The
process group id.", required = true) @PathParam("id") final String groupId) {
+ public Response getVersionInformation(
+ @Parameter(description = "The process group id.", required = true)
@PathParam("id") final String groupId) {
if (isReplicateRequest()) {
return replicate(HttpMethod.GET);
@@ -161,7 +162,9 @@ public class VersionsResource extends
FlowUpdateResource<VersionControlInformati
@SecurityRequirement(name = "Read -
/process-groups/{uuid}")
}
)
- public Response exportFlowVersion(@Parameter(description = "The process
group id.", required = true) @PathParam("id") final String groupId) {
+ public Response exportFlowVersion(
+ @Parameter(description = "The process group id.", required = true)
@PathParam("id") final String groupId) {
+
// authorize access
serviceFacade.authorizeAccess(lookup -> {
final ProcessGroupAuthorizable groupAuthorizable =
lookup.getProcessGroup(groupId);
@@ -289,8 +292,9 @@ public class VersionsResource extends
FlowUpdateResource<VersionControlInformati
@SecurityRequirement(name = "Only the user that submitted
the request can update it")
}
)
- public Response updateVersionControlRequest(@Parameter(description = "The
request ID.") @PathParam("id") final String requestId,
- @Parameter(description = "The
version control component mapping.", required = true) final
VersionControlComponentMappingEntity requestEntity) {
+ public Response updateVersionControlRequest(
+ @Parameter(description = "The request ID.") @PathParam("id") final
String requestId,
+ @Parameter(description = "The version control component mapping.",
required = true) final VersionControlComponentMappingEntity requestEntity) {
if (requestEntity == null) {
throw new IllegalArgumentException("Version control information
must be specified.");
@@ -649,8 +653,7 @@ public class VersionsResource extends
FlowUpdateResource<VersionControlInformati
"Failed to create a Version Control Request across all
nodes in the cluster. Received response code " + clusterResponse.getStatus() +
" with content: " + errorResponse);
}
- final String requestId = getResponseEntity(clusterResponse,
String.class);
- return requestId;
+ return getResponseEntity(clusterResponse, String.class);
}
private void replicateVersionControlMapping(final
VersionControlComponentMappingEntity mappingEntity, final
StartVersionControlRequestEntity requestEntity,
@@ -795,8 +798,9 @@ public class VersionsResource extends
FlowUpdateResource<VersionControlInformati
@SecurityRequirement(name = "Write -
/process-groups/{uuid}")
}
)
- public Response updateFlowVersion(@Parameter(description = "The process
group id.") @PathParam("id") final String groupId,
- @Parameter(description = "The controller
service configuration details.", required = true) final
VersionedFlowSnapshotEntity requestEntity) {
+ public Response updateFlowVersion(
+ @Parameter(description = "The process group id.") @PathParam("id")
final String groupId,
+ @Parameter(description = "The controller service configuration
details.", required = true) final VersionedFlowSnapshotEntity requestEntity) {
if (requestEntity == null) {
throw new IllegalArgumentException("Version control information
must be specified.");
@@ -894,7 +898,9 @@ public class VersionsResource extends
FlowUpdateResource<VersionControlInformati
@SecurityRequirement(name = "Only the user that submitted
the request can get it")
}
)
- public Response getUpdateRequest(@Parameter(description = "The ID of the
Update Request") @PathParam("id") final String updateRequestId) {
+ public Response getUpdateRequest(
+ @Parameter(description = "The ID of the Update Request")
@PathParam("id") final String updateRequestId) {
+
return retrieveFlowUpdateRequest("update-requests", updateRequestId);
}
@@ -920,7 +926,9 @@ public class VersionsResource extends
FlowUpdateResource<VersionControlInformati
@SecurityRequirement(name = "Only the user that submitted
the request can get it")
}
)
- public Response getRevertRequest(@Parameter(description = "The ID of the
Revert Request") @PathParam("id") final String revertRequestId) {
+ public Response getRevertRequest(
+ @Parameter(description = "The ID of the Revert Request")
@PathParam("id") final String revertRequestId) {
+
return retrieveFlowUpdateRequest("revert-requests", revertRequestId);
}
@@ -953,7 +961,7 @@ public class VersionsResource extends
FlowUpdateResource<VersionControlInformati
@QueryParam(DISCONNECTED_NODE_ACKNOWLEDGED) @DefaultValue("false")
final Boolean disconnectedNodeAcknowledged,
@Parameter(description = "The ID of the Update Request")
@PathParam("id") final String updateRequestId) {
- return deleteFlowUpdateRequest("update-requests", updateRequestId,
disconnectedNodeAcknowledged.booleanValue());
+ return deleteFlowUpdateRequest("update-requests", updateRequestId,
disconnectedNodeAcknowledged);
}
@DELETE
@@ -985,7 +993,7 @@ public class VersionsResource extends
FlowUpdateResource<VersionControlInformati
@QueryParam(DISCONNECTED_NODE_ACKNOWLEDGED) @DefaultValue("false")
final Boolean disconnectedNodeAcknowledged,
@Parameter(description = "The ID of the Revert Request")
@PathParam("id") final String revertRequestId) {
- return deleteFlowUpdateRequest("revert-requests", revertRequestId,
disconnectedNodeAcknowledged.booleanValue());
+ return deleteFlowUpdateRequest("revert-requests", revertRequestId,
disconnectedNodeAcknowledged);
}
@POST
@@ -1088,8 +1096,9 @@ public class VersionsResource extends
FlowUpdateResource<VersionControlInformati
@SecurityRequirement(name = "Read -
/parameter-contexts/{uuid} - For any Parameter Context that is referenced by a
Property that is changed, added, or removed")
}
)
- public Response initiateRevertFlowVersion(@Parameter(description = "The
process group id.") @PathParam("id") final String groupId,
- @Parameter(description = "The
Version Control Information to revert to.", required = true) final
VersionControlInformationEntity requestEntity) {
+ public Response initiateRevertFlowVersion(
+ @Parameter(description = "The process group id.") @PathParam("id")
final String groupId,
+ @Parameter(description = "The Version Control Information to
revert to.", required = true) final VersionControlInformationEntity
requestEntity) {
if (requestEntity == null) {
throw new IllegalArgumentException("Version control information
must be specified.");