Skip to content

Changing modelAsString = true#23333

Merged
jsquire merged 1 commit intoAzure:mainfrom
conniey:model-as-string
Mar 28, 2023
Merged

Changing modelAsString = true#23333
jsquire merged 1 commit intoAzure:mainfrom
conniey:model-as-string

Conversation

@conniey
Copy link
Member

@conniey conniey commented Mar 28, 2023

Description

AccessRights, NamespaceType, EntityAvailabilityStatus, EntityStatus, MessagingSku, and NamespaceType should be generated as ExtensibleStringEnum<T> rather than just enums. Fixing by setting modelAsString=true

@openapi-workflow-bot
Copy link

Hi, @conniey Thanks for your PR. I am workflow bot for review process. Here are some small tips.

  • Please ensure to do self-check against checklists in first PR comment.
  • PR assignee is the person auto-assigned and responsible for your current PR reviewing and merging.
  • For specs comparison cross API versions, Use API Specs Comparison Report Generator
  • If there is CI failure(s), to fix CI error(s) is mandatory for PR merging; or you need to provide justification in PR comment for explanation. How to fix?

  • Any feedback about review process or workflow bot, pls contact swagger and tools team. vscswagger@microsoft.com

    @openapi-pipeline-app
    Copy link

    openapi-pipeline-app bot commented Mar 28, 2023

    Swagger Validation Report

    ️❌BreakingChange: 12 Errors, 0 Warnings failed [Detail]
    compared swaggers (via Oad v0.10.4)] new version base version
    servicebus.json 2021-05(36bbfdc) 2021-05(main)
    Rule Message
    1047 - XmsEnumChanged The new version has a different x-ms-enum 'modelAsString' than the previous one.
    New: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L472:9
    Old: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L472:9
    1047 - XmsEnumChanged The new version has a different x-ms-enum 'modelAsString' than the previous one.
    New: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L93:5
    Old: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L93:5
    1047 - XmsEnumChanged The new version has a different x-ms-enum 'modelAsString' than the previous one.
    New: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L151:11
    Old: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L151:11
    1047 - XmsEnumChanged The new version has a different x-ms-enum 'modelAsString' than the previous one.
    New: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L712:9
    Old: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L712:9
    1047 - XmsEnumChanged The new version has a different x-ms-enum 'modelAsString' than the previous one.
    New: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L786:9
    Old: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L786:9
    1047 - XmsEnumChanged The new version has a different x-ms-enum 'modelAsString' than the previous one.
    New: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L1090:9
    Old: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L1090:9
    1047 - XmsEnumChanged The new version has a different x-ms-enum 'modelAsString' than the previous one.
    New: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L1157:9
    Old: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L1157:9
    1047 - XmsEnumChanged The new version has a different x-ms-enum 'modelAsString' than the previous one.
    New: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L1403:9
    Old: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L1403:9
    1047 - XmsEnumChanged The new version has a different x-ms-enum 'modelAsString' than the previous one.
    New: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L1469:9
    Old: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L1469:9
    1047 - XmsEnumChanged The new version has a different x-ms-enum 'modelAsString' than the previous one.
    New: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L328:5
    Old: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L328:5
    1047 - XmsEnumChanged The new version has a different x-ms-enum 'modelAsString' than the previous one.
    New: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L347:5
    Old: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L347:5
    1047 - XmsEnumChanged The new version has a different x-ms-enum 'modelAsString' than the previous one.
    New: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L430:5
    Old: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L430:5
    ️️✔️Breaking Change(Cross-Version) succeeded [Detail] [Expand]
    There are no breaking changes.
    ️️✔️CredScan succeeded [Detail] [Expand]
    There is no credential detected.
    ️⚠️LintDiff: 0 Warnings warning [Detail]
    compared tags (via openapi-validator v2.0.0) new version base version
    package-2021-05 package-2021-05(36bbfdc) package-2021-05(main)

    The following errors/warnings exist before current PR submission:

    Only 30 items are listed, please refer to log for more details.

    Rule Message
    ⚠️ VersionConvention API version should be a date in YYYY-MM-DD format, optionally suffixed with '-preview'.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L4
    ⚠️ DeprecatedXmsCodeGenerationSetting The x-ms-code-generation-setting extension is being deprecated. Please remove it and move settings to readme file for code generation.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L7
    ⚠️ EnumInsteadOfBoolean Booleans properties are not descriptive in all cases and can make them to use, evaluate whether is makes sense to keep the property as boolean or turn it into an enum.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L83
    ⚠️ EnumInsteadOfBoolean Booleans properties are not descriptive in all cases and can make them to use, evaluate whether is makes sense to keep the property as boolean or turn it into an enum.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L615
    ⚠️ EnumInsteadOfBoolean Booleans properties are not descriptive in all cases and can make them to use, evaluate whether is makes sense to keep the property as boolean or turn it into an enum.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L623
    ⚠️ EnumInsteadOfBoolean Booleans properties are not descriptive in all cases and can make them to use, evaluate whether is makes sense to keep the property as boolean or turn it into an enum.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L640
    ⚠️ EnumInsteadOfBoolean Booleans properties are not descriptive in all cases and can make them to use, evaluate whether is makes sense to keep the property as boolean or turn it into an enum.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L666
    ⚠️ EnumInsteadOfBoolean Booleans properties are not descriptive in all cases and can make them to use, evaluate whether is makes sense to keep the property as boolean or turn it into an enum.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L692
    ⚠️ EnumInsteadOfBoolean Booleans properties are not descriptive in all cases and can make them to use, evaluate whether is makes sense to keep the property as boolean or turn it into an enum.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L758
    ⚠️ EnumInsteadOfBoolean Booleans properties are not descriptive in all cases and can make them to use, evaluate whether is makes sense to keep the property as boolean or turn it into an enum.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L778
    ⚠️ EnumInsteadOfBoolean Booleans properties are not descriptive in all cases and can make them to use, evaluate whether is makes sense to keep the property as boolean or turn it into an enum.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L789
    ⚠️ EnumInsteadOfBoolean Booleans properties are not descriptive in all cases and can make them to use, evaluate whether is makes sense to keep the property as boolean or turn it into an enum.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L1028
    ⚠️ EnumInsteadOfBoolean Booleans properties are not descriptive in all cases and can make them to use, evaluate whether is makes sense to keep the property as boolean or turn it into an enum.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L1045
    ⚠️ EnumInsteadOfBoolean Booleans properties are not descriptive in all cases and can make them to use, evaluate whether is makes sense to keep the property as boolean or turn it into an enum.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L1062
    ⚠️ EnumInsteadOfBoolean Booleans properties are not descriptive in all cases and can make them to use, evaluate whether is makes sense to keep the property as boolean or turn it into an enum.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L1070
    ⚠️ EnumInsteadOfBoolean Booleans properties are not descriptive in all cases and can make them to use, evaluate whether is makes sense to keep the property as boolean or turn it into an enum.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L1120
    ⚠️ EnumInsteadOfBoolean Booleans properties are not descriptive in all cases and can make them to use, evaluate whether is makes sense to keep the property as boolean or turn it into an enum.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L1149
    ⚠️ EnumInsteadOfBoolean Booleans properties are not descriptive in all cases and can make them to use, evaluate whether is makes sense to keep the property as boolean or turn it into an enum.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L1160
    ⚠️ EnumInsteadOfBoolean Booleans properties are not descriptive in all cases and can make them to use, evaluate whether is makes sense to keep the property as boolean or turn it into an enum.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L1168
    ⚠️ EnumInsteadOfBoolean Booleans properties are not descriptive in all cases and can make them to use, evaluate whether is makes sense to keep the property as boolean or turn it into an enum.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L1336
    ⚠️ EnumInsteadOfBoolean Booleans properties are not descriptive in all cases and can make them to use, evaluate whether is makes sense to keep the property as boolean or turn it into an enum.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L1353
    ⚠️ EnumInsteadOfBoolean Booleans properties are not descriptive in all cases and can make them to use, evaluate whether is makes sense to keep the property as boolean or turn it into an enum.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L1361
    ⚠️ EnumInsteadOfBoolean Booleans properties are not descriptive in all cases and can make them to use, evaluate whether is makes sense to keep the property as boolean or turn it into an enum.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L1395
    ⚠️ PropertyDescription Property should have a description.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L1594
    ⚠️ PropertyDescription Property should have a description.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L1601
    ⚠️ SchemaDescriptionOrTitle Schema should have a description or title.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L1610
    ⚠️ PropertyDescription Property should have a description.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L1621
    ⚠️ SchemaDescriptionOrTitle Schema should have a description or title.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L1631
    ⚠️ PropertyDescription Property should have a description.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L1639
    ⚠️ PropertyDescription Property should have a description.
    Location: Microsoft.ServiceBus/stable/2021-05/servicebus.json#L1646
    ️️✔️Avocado succeeded [Detail] [Expand]
    Validation passes for Avocado.
    ️️✔️ApiReadinessCheck succeeded [Detail] [Expand]
    ️⚠️~[Staging] ServiceAPIReadinessTest: 0 Warnings warning [Detail]

    API Test is not triggered due to precheck failure. Check pipeline log for details.

    ️️✔️SwaggerAPIView succeeded [Detail] [Expand]
    ️️✔️CadlAPIView succeeded [Detail] [Expand]
    ️️✔️TypeSpecAPIView succeeded [Detail] [Expand]
    ️️✔️ModelValidation succeeded [Detail] [Expand]
    Validation passes for ModelValidation.
    ️️✔️SemanticValidation succeeded [Detail] [Expand]
    Validation passes for SemanticValidation.
    ️️✔️PoliCheck succeeded [Detail] [Expand]
    Validation passed for PoliCheck.
    ️️✔️PrettierCheck succeeded [Detail] [Expand]
    Validation passes for PrettierCheck.
    ️️✔️SpellCheck succeeded [Detail] [Expand]
    Validation passes for SpellCheck.
    ️️✔️Lint(RPaaS) succeeded [Detail] [Expand]
    Validation passes for Lint(RPaaS).
    ️️✔️CadlValidation succeeded [Detail] [Expand]
    Validation passes for CadlValidation.
    ️️✔️TypeSpec Validation succeeded [Detail] [Expand]
    Validation passes for TypeSpec Validation.
    ️️✔️PR Summary succeeded [Detail] [Expand]
    Validation passes for Summary.
    Posted by Swagger Pipeline | How to fix these errors?

    @openapi-pipeline-app
    Copy link

    openapi-pipeline-app bot commented Mar 28, 2023

    Swagger pipeline restarted successfully, please wait for status update in this comment.

    @openapi-pipeline-app
    Copy link

    openapi-pipeline-app bot commented Mar 28, 2023

    Generated ApiView

    Language Package Name ApiView Link
    Swagger Microsoft.ServiceBus https://apiview.dev/Assemblies/Review/301507784dba47e4a72afda76133225a

    @ghost ghost added the Service Bus label Mar 28, 2023
    @AzureRestAPISpecReview AzureRestAPISpecReview added BreakingChangeReviewRequired <valid label in PR review process>add this label when breaking change review is required data-plane labels Mar 28, 2023
    @openapi-workflow-bot
    Copy link

    Hi @conniey, one or multiple breaking change(s) is detected in your PR. Please check out the breaking change(s), and provide business justification in the PR comment and @ PR assignee why you must have these change(s), and how external customer impact can be mitigated. Please ensure to follow breaking change policy to request breaking change review and approval before proceeding swagger PR review.
    Action: To initiate an evaluation of the breaking change, create a new intake using the template for breaking changes. Addition details on the process and office hours are on the Breaking change Wiki.
    If you want to know the production traffic statistic, please see ARM Traffic statistic.
    If you think it is false positive breaking change, please provide the reasons in the PR comment, report to Swagger Tooling Team via https://aka.ms/swaggerfeedback.
    Note: To avoid breaking change, you can refer to Shift Left Solution for detecting breaking change in early phase at your service code repository.

    @jsquire jsquire added Approved-BreakingChange DO NOT USE! OBSOLETE label. See https://github.com/Azure/azure-sdk-tools/issues/6374 and removed BreakingChangeReviewRequired <valid label in PR review process>add this label when breaking change review is required labels Mar 28, 2023
    @jsquire jsquire merged commit e3f5ba4 into Azure:main Mar 28, 2023
    JoshLove-msft pushed a commit to JoshLove-msft/azure-rest-api-specs that referenced this pull request Apr 25, 2023
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

    Labels

    Approved-BreakingChange DO NOT USE! OBSOLETE label. See https://github.com/Azure/azure-sdk-tools/issues/6374 data-plane Service Bus

    Projects

    None yet

    Development

    Successfully merging this pull request may close these issues.

    4 participants