You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@nifi.apache.org by "Bryan Bende (Jira)" <ji...@apache.org> on 2023/11/02 20:58:00 UTC
[jira] [Commented] (NIFI-12302) Registry swagger enums are generated with incorrect values
[ https://issues.apache.org/jira/browse/NIFI-12302?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17782325#comment-17782325 ]
Bryan Bende commented on NIFI-12302:
------------------------------------
I think the reason it is correct in the places where it is used directly in a resource is because it is defined like this:
{code:java}
@ApiParam(value = "The type of bundles to return", allowableValues = BundleTypeValues.ALL_VALUES)
final BundleType bundleType, {code}
So its similar to what you mentioned from NiFi. I think we possibly just need to add the same allowableValues in the BundleInfo class where it defines:
{code:java}
@ApiModelProperty("The type of bundle (i.e. a NiFi NAR vs MiNiFi CPP)")
public BundleType getBundleType() {
return bundleType;
} {code}
> Registry swagger enums are generated with incorrect values
> ----------------------------------------------------------
>
> Key: NIFI-12302
> URL: https://issues.apache.org/jira/browse/NIFI-12302
> Project: Apache NiFi
> Issue Type: Bug
> Components: NiFi Registry
> Affects Versions: 2.0.0, 1.24.0, 1.23.2
> Reporter: Zackeus Bengtsson
> Priority: Minor
>
> In the generated swagger.json api definition, objects that contain the BundleType enum, like BundleInfo, have the wrong enum values. The enum values for bundleType should be "nifi-nar" and "minifi-cpp", but are currently "NIFI_NAR" and "MINIFI_CPP". For the endpoint resource defenitions in the swagger file, the enum values are correctly generated.
> For the BundleType object, the values are correct. The issue only occurs for objects using the containing the enum object
--
This message was sent by Atlassian Jira
(v8.20.10#820010)