Skip to content

EventGrid TypeSpec #21739

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 70 commits into
base: main
Choose a base branch
from
Draft

EventGrid TypeSpec #21739

wants to merge 70 commits into from

Conversation

l0lawrence
Copy link
Member

No description provided.

@openapi-workflow-bot
Copy link

Hi, @l0lawrence 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. [email protected]

    @ghost ghost added the Event Grid label Dec 2, 2022
    }

    @doc("Event data for Microsoft.Devices.DeviceCreated event.")
    model IotHubDeviceCreatedEventData extends DeviceLifeCycleEventProperties {}
    Copy link
    Member

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    Unless this is done only to reduce changes to generated openapi2 documents, this should be a spread. We want to avoid extends in Azure unless it is a discriminated type relationship...

    @lmazuel lmazuel changed the title EventGrid CADL EventGrid TypeSpec Feb 14, 2023
    @openapi-pipeline-app
    Copy link

    openapi-pipeline-app bot commented Feb 17, 2023

    Swagger Validation Report

    ️️✔️BreakingChange succeeded [Detail] [Expand]
    There are no breaking changes.
    ️️✔️Breaking Change(Cross-Version) succeeded [Detail] [Expand]
    There are no breaking changes.
    ️️✔️CredScan succeeded [Detail] [Expand]
    There is no credential detected.
    ️️✔️LintDiff succeeded [Detail] [Expand]
    Validation passes for LintDiff.
    compared tags (via openapi-validator v2.0.0) new version base version
    default default(a19e059) default(main)
    ️❌Avocado: 20 Errors, 0 Warnings failed [Detail]
    Rule Message
    UNREFERENCED_JSON_FILE The swagger JSON file is not referenced from the readme file.
    readme: specification/eventgrid/data-plane/readme.md
    json: data-plane/typespec/swagger/ApiManagement.json
    UNREFERENCED_JSON_FILE The swagger JSON file is not referenced from the readme file.
    readme: specification/eventgrid/data-plane/readme.md
    json: data-plane/typespec/swagger/AppConfiguration.json
    UNREFERENCED_JSON_FILE The swagger JSON file is not referenced from the readme file.
    readme: specification/eventgrid/data-plane/readme.md
    json: data-plane/typespec/swagger/AzureCommunicationServices.json
    UNREFERENCED_JSON_FILE The swagger JSON file is not referenced from the readme file.
    readme: specification/eventgrid/data-plane/readme.md
    json: data-plane/typespec/swagger/ContainerRegistry.json
    UNREFERENCED_JSON_FILE The swagger JSON file is not referenced from the readme file.
    readme: specification/eventgrid/data-plane/readme.md
    json: data-plane/typespec/swagger/ContainerService.json
    UNREFERENCED_JSON_FILE The swagger JSON file is not referenced from the readme file.
    readme: specification/eventgrid/data-plane/readme.md
    json: data-plane/typespec/swagger/EventGrid.json
    UNREFERENCED_JSON_FILE The swagger JSON file is not referenced from the readme file.
    readme: specification/eventgrid/data-plane/readme.md
    json: data-plane/typespec/swagger/EventHub.json
    UNREFERENCED_JSON_FILE The swagger JSON file is not referenced from the readme file.
    readme: specification/eventgrid/data-plane/readme.md
    json: data-plane/typespec/swagger/HealthcareApis.json
    UNREFERENCED_JSON_FILE The swagger JSON file is not referenced from the readme file.
    readme: specification/eventgrid/data-plane/readme.md
    json: data-plane/typespec/swagger/IotHub.json
    UNREFERENCED_JSON_FILE The swagger JSON file is not referenced from the readme file.
    readme: specification/eventgrid/data-plane/readme.md
    json: data-plane/typespec/swagger/KeyVault.json
    UNREFERENCED_JSON_FILE The swagger JSON file is not referenced from the readme file.
    readme: specification/eventgrid/data-plane/readme.md
    json: data-plane/typespec/swagger/MachineLearningServices.json
    UNREFERENCED_JSON_FILE The swagger JSON file is not referenced from the readme file.
    readme: specification/eventgrid/data-plane/readme.md
    json: data-plane/typespec/swagger/Maps.json
    UNREFERENCED_JSON_FILE The swagger JSON file is not referenced from the readme file.
    readme: specification/eventgrid/data-plane/readme.md
    json: data-plane/typespec/swagger/MediaServices.json
    UNREFERENCED_JSON_FILE The swagger JSON file is not referenced from the readme file.
    readme: specification/eventgrid/data-plane/readme.md
    json: data-plane/typespec/swagger/PolicyInsights.json
    UNREFERENCED_JSON_FILE The swagger JSON file is not referenced from the readme file.
    readme: specification/eventgrid/data-plane/readme.md
    json: data-plane/typespec/swagger/RedisCache.json
    UNREFERENCED_JSON_FILE The swagger JSON file is not referenced from the readme file.
    readme: specification/eventgrid/data-plane/readme.md
    json: data-plane/typespec/swagger/Resources.json
    UNREFERENCED_JSON_FILE The swagger JSON file is not referenced from the readme file.
    readme: specification/eventgrid/data-plane/readme.md
    json: data-plane/typespec/swagger/ServiceBus.json
    UNREFERENCED_JSON_FILE The swagger JSON file is not referenced from the readme file.
    readme: specification/eventgrid/data-plane/readme.md
    json: data-plane/typespec/swagger/SignalRService.json
    UNREFERENCED_JSON_FILE The swagger JSON file is not referenced from the readme file.
    readme: specification/eventgrid/data-plane/readme.md
    json: data-plane/typespec/swagger/Storage.json
    UNREFERENCED_JSON_FILE The swagger JSON file is not referenced from the readme file.
    readme: specification/eventgrid/data-plane/readme.md
    json: data-plane/typespec/swagger/Web.json
    ️️✔️ApiReadinessCheck succeeded [Detail] [Expand]
    ️❌~[Staging] ServiceAPIReadinessTest: 0 Errors, 0 Warnings failed [Detail]

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

    ️️✔️SwaggerAPIView succeeded [Detail] [Expand]
    ️️✔️CadlAPIView succeeded [Detail] [Expand]
    ️❌ModelValidation: 3 Errors, 0 Warnings failed [Detail]
    Rule Message
    XMS_EXAMPLE_NOTFOUND_ERROR x-ms-example not found in PublishEventGridEvents.
    Url: data-plane/typespec/swagger/EventGrid.json#L43:15
    XMS_EXAMPLE_NOTFOUND_ERROR x-ms-example not found in PublishCloudEventEvents.
    Url: data-plane/typespec/swagger/EventGrid.json#L75:15
    XMS_EXAMPLE_NOTFOUND_ERROR x-ms-example not found in PublishCustomEventEvents.
    Url: data-plane/typespec/swagger/EventGrid.json#L110:15
    ️️✔️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: 42 Errors, 0 Warnings failed [Detail]

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

    Rule Message
    HowToFix Unknown word (typespec), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L9:23
    HowToFix Unknown word (typespec), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L10:23
    HowToFix Unknown word (typespec), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L11:23
    HowToFix Unknown word (typespec), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L12:11
    HowToFix Unknown word (globby), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L185:10
    HowToFix Unknown word (picocolors), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L191:10
    HowToFix Unknown word (nodelib), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L242:20
    HowToFix Unknown word (scandir), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L242:31
    HowToFix Unknown word (nodelib), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L247:11
    HowToFix Unknown word (nodelib), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L254:20
    HowToFix Unknown word (nodelib), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L262:20
    HowToFix Unknown word (scandir), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L267:22
    HowToFix Unknown word (fastq), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L268:10
    HowToFix Unknown word (globby), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L282:10
    HowToFix Unknown word (picocolors), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L288:10
    HowToFix Unknown word (cliui), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L479:19
    HowToFix Unknown word (fastq), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L589:19
    HowToFix Unknown word (reusify), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L594:10
    HowToFix Unknown word (domexception), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L612:15
    HowToFix Unknown word (formdata), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L630:19
    HowToFix Unknown word (globby), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L660:19
    HowToFix Unknown word (extglob), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L703:22
    HowToFix Unknown word (extglob), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L724:13
    HowToFix Unknown word (kleur), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L759:19
    HowToFix Unknown word (yallist), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L780:10
    HowToFix Unknown word (picomatch), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L800:10
    HowToFix Unknown word (domexception), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L834:24
    HowToFix Unknown word (formdata), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L859:10
    HowToFix Unknown word (opencollective), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L865:18
    HowToFix Unknown word (picocolors), please fix the error or add words to ./custom-words.txt
    path: eventgrid/data-plane/typespec/package-lock.json#L912:19
    ️️✔️Lint(RPaaS) succeeded [Detail] [Expand]
    Validation passes for Lint(RPaaS).
    ️❌CadlValidation: 20 Errors, 0 Warnings failed [Detail]
    Rule Message
    MissingCadlFile "details":"The swagger specification/eventgrid/data-plane/typespec/swagger/ApiManagement.json is generated from cadl files,
    but the cadl project with '@azure-tools/cadl-autorest' emitter is missing in the PR. Please add the missing cadl project or emitter configuration."
    MissingCadlFile "details":"The swagger specification/eventgrid/data-plane/typespec/swagger/AppConfiguration.json is generated from cadl files,
    but the cadl project with '@azure-tools/cadl-autorest' emitter is missing in the PR. Please add the missing cadl project or emitter configuration."
    MissingCadlFile "details":"The swagger specification/eventgrid/data-plane/typespec/swagger/AzureCommunicationServices.json is generated from cadl files,
    but the cadl project with '@azure-tools/cadl-autorest' emitter is missing in the PR. Please add the missing cadl project or emitter configuration."
    MissingCadlFile "details":"The swagger specification/eventgrid/data-plane/typespec/swagger/ContainerRegistry.json is generated from cadl files,
    but the cadl project with '@azure-tools/cadl-autorest' emitter is missing in the PR. Please add the missing cadl project or emitter configuration."
    MissingCadlFile "details":"The swagger specification/eventgrid/data-plane/typespec/swagger/ContainerService.json is generated from cadl files,
    but the cadl project with '@azure-tools/cadl-autorest' emitter is missing in the PR. Please add the missing cadl project or emitter configuration."
    MissingCadlFile "details":"The swagger specification/eventgrid/data-plane/typespec/swagger/EventGrid.json is generated from cadl files,
    but the cadl project with '@azure-tools/cadl-autorest' emitter is missing in the PR. Please add the missing cadl project or emitter configuration."
    MissingCadlFile "details":"The swagger specification/eventgrid/data-plane/typespec/swagger/EventHub.json is generated from cadl files,
    but the cadl project with '@azure-tools/cadl-autorest' emitter is missing in the PR. Please add the missing cadl project or emitter configuration."
    MissingCadlFile "details":"The swagger specification/eventgrid/data-plane/typespec/swagger/HealthcareApis.json is generated from cadl files,
    but the cadl project with '@azure-tools/cadl-autorest' emitter is missing in the PR. Please add the missing cadl project or emitter configuration."
    MissingCadlFile "details":"The swagger specification/eventgrid/data-plane/typespec/swagger/IotHub.json is generated from cadl files,
    but the cadl project with '@azure-tools/cadl-autorest' emitter is missing in the PR. Please add the missing cadl project or emitter configuration."
    MissingCadlFile "details":"The swagger specification/eventgrid/data-plane/typespec/swagger/KeyVault.json is generated from cadl files,
    but the cadl project with '@azure-tools/cadl-autorest' emitter is missing in the PR. Please add the missing cadl project or emitter configuration."
    MissingCadlFile "details":"The swagger specification/eventgrid/data-plane/typespec/swagger/MachineLearningServices.json is generated from cadl files,
    but the cadl project with '@azure-tools/cadl-autorest' emitter is missing in the PR. Please add the missing cadl project or emitter configuration."
    MissingCadlFile "details":"The swagger specification/eventgrid/data-plane/typespec/swagger/Maps.json is generated from cadl files,
    but the cadl project with '@azure-tools/cadl-autorest' emitter is missing in the PR. Please add the missing cadl project or emitter configuration."
    MissingCadlFile "details":"The swagger specification/eventgrid/data-plane/typespec/swagger/MediaServices.json is generated from cadl files,
    but the cadl project with '@azure-tools/cadl-autorest' emitter is missing in the PR. Please add the missing cadl project or emitter configuration."
    MissingCadlFile "details":"The swagger specification/eventgrid/data-plane/typespec/swagger/PolicyInsights.json is generated from cadl files,
    but the cadl project with '@azure-tools/cadl-autorest' emitter is missing in the PR. Please add the missing cadl project or emitter configuration."
    MissingCadlFile "details":"The swagger specification/eventgrid/data-plane/typespec/swagger/RedisCache.json is generated from cadl files,
    but the cadl project with '@azure-tools/cadl-autorest' emitter is missing in the PR. Please add the missing cadl project or emitter configuration."
    MissingCadlFile "details":"The swagger specification/eventgrid/data-plane/typespec/swagger/Resources.json is generated from cadl files,
    but the cadl project with '@azure-tools/cadl-autorest' emitter is missing in the PR. Please add the missing cadl project or emitter configuration."
    MissingCadlFile "details":"The swagger specification/eventgrid/data-plane/typespec/swagger/ServiceBus.json is generated from cadl files,
    but the cadl project with '@azure-tools/cadl-autorest' emitter is missing in the PR. Please add the missing cadl project or emitter configuration."
    MissingCadlFile "details":"The swagger specification/eventgrid/data-plane/typespec/swagger/SignalRService.json is generated from cadl files,
    but the cadl project with '@azure-tools/cadl-autorest' emitter is missing in the PR. Please add the missing cadl project or emitter configuration."
    MissingCadlFile "details":"The swagger specification/eventgrid/data-plane/typespec/swagger/Storage.json is generated from cadl files,
    but the cadl project with '@azure-tools/cadl-autorest' emitter is missing in the PR. Please add the missing cadl project or emitter configuration."
    MissingCadlFile "details":"The swagger specification/eventgrid/data-plane/typespec/swagger/Web.json is generated from cadl files,
    but the cadl project with '@azure-tools/cadl-autorest' emitter is missing in the PR. Please add the missing cadl project or emitter configuration."
    ️️✔️PR Summary succeeded [Detail] [Expand]
    Validation passes for Summary.
    Posted by Swagger Pipeline | How to fix these errors?

    @mikeharder
    Copy link
    Member

    @l0lawrence: Can this be closed as a dup of #23204?

    @l0lawrence
    Copy link
    Member Author

    @l0lawrence: Can this be closed as a dup of #23204?

    These are all the system events in EventGrid in typespec, #23204 was the EGv2 preview api!

    @mikeharder
    Copy link
    Member

    @l0lawrence: Can this be closed as a dup of #23204?

    These are all the system events in EventGrid in typespec, #23204 was the EGv2 preview api!

    So this is another spec that will be added to the repo eventually? If so, please make sure it is passing all the checks (including specs - typespec - ci) before merging.

    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    Projects
    None yet
    Development

    Successfully merging this pull request may close these issues.

    6 participants