Skip to content

[Egv2] Encode param#24080

Merged
lmazuel merged 3 commits intoAzure:feature/eventgrid/typespecfrom
l0lawrence:encode
May 22, 2023
Merged

[Egv2] Encode param#24080
lmazuel merged 3 commits intoAzure:feature/eventgrid/typespecfrom
l0lawrence:encode

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. vscswagger@microsoft.com

    @openapi-pipeline-app
    Copy link

    openapi-pipeline-app bot commented May 19, 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.
    ️️✔️LintDiff succeeded [Detail] [Expand]
    Validation passes for LintDiff.
    ️️✔️Avocado succeeded [Detail] [Expand]
    Validation passes for Avocado.
    ️️✔️SwaggerAPIView succeeded [Detail] [Expand]
    ️️✔️CadlAPIView succeeded [Detail] [Expand]
    ️❌TypeSpecAPIView: 0 Errors, 1 Warnings failed [Detail]
    Rule Message
    ⚠️ Failed to generate TypeSpec APIView. Please check the detail log and make sure TypeSpec compiler version is the latest. "How to fix":"Check the detailed log and verify if the TypeSpec emitter is able to create API review file for the changes in PR."
    ️️✔️ModelValidation succeeded [Detail] [Expand]
    Validation passes for ModelValidation.
    ️️✔️SemanticValidation succeeded [Detail] [Expand]
    Validation passes for SemanticValidation.
    ️️✔️PrettierCheck succeeded [Detail] [Expand]
    Validation passes for PrettierCheck.
    ️️✔️SpellCheck succeeded [Detail] [Expand]
    Validation passes for SpellCheck.
    ️️✔️CadlValidation succeeded [Detail] [Expand]
    Validation passes for CadlValidation.
    ️❌TypeSpec Validation: 3 Errors, 1 Warnings failed [Detail]
    Rule Message
    unknown-identifier Unknown identifier encode
    Location: specification/eventgrid/Azure.Messaging.EventGrid/main.tsp#L219
    unknown-decorator Unknown decorator
    Location: specification/eventgrid/Azure.Messaging.EventGrid/main.tsp#L219
    MissingExamplesDirectory "details":"The 'examples' directory is missing in the typespec folder specification/eventgrid/Azure.Messaging.EventGrid,
    please ensure the 'examples' is added in the PR."
    ⚠️ MissingTypeSpecProjectConfig "details":"The configuration 'azure-resource-provider-folder' for '@azure-tools/typespec-autorest' is missing in the tspconfig.yaml under folder specification/eventgrid/Azure.Messaging.EventGrid,
    please ensure it is added in the configuration of the emitter '@azure-tools/typespec-autorest'."
    ️️✔️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 May 19, 2023

    Swagger Generation Artifacts

    ️️✔️ApiDocPreview succeeded [Detail] [Expand]
    ️️✔️SDK Breaking Change Tracking succeeded [Detail] [Expand]

    Breaking Changes Tracking


    ️⚠️ azure-sdk-for-python warning [Detail]
    • ⚠️Warning [Logs] Generate from 147e993b7a007164386c648d6e20c107ea98595b. SDK Automation 14.0.0
      command	sh scripts/automation_init.sh ../azure-sdk-for-python_tmp/initInput.json ../azure-sdk-for-python_tmp/initOutput.json
      cmderr	[automation_init.sh] WARNING: Skipping azure-nspkg as it is not installed.
      command	sh scripts/automation_generate.sh ../azure-sdk-for-python_tmp/generateInput.json ../azure-sdk-for-python_tmp/generateOutput.json
      cmderr	[automation_generate.sh]
      cmderr	[automation_generate.sh] npm notice New minor version of npm available! 9.5.1 -> 9.6.7
      cmderr	[automation_generate.sh] npm notice Changelog: <https://github.com/npm/cli/releases/tag/v9.6.7>
      cmderr	[automation_generate.sh] npm notice Run `npm install -g npm@9.6.7` to update!
      cmderr	[automation_generate.sh] npm notice
    • ️✔️azure-eventgrid [View full logs]  [Preview SDK Changes]
      info	[Changelog] data-plan skip changelog generation temporarily
    ️️✔️ azure-sdk-for-net-track2 succeeded [Detail] [Expand]
    • ️✔️Succeeded [Logs] Generate from 147e993b7a007164386c648d6e20c107ea98595b. SDK Automation 14.0.0
      command	pwsh ./eng/scripts/Automation-Sdk-Init.ps1 ../azure-sdk-for-net_tmp/initInput.json ../azure-sdk-for-net_tmp/initOutput.json
      command	pwsh ./eng/scripts/Invoke-GenerateAndBuildV2.ps1 ../azure-sdk-for-net_tmp/generateInput.json ../azure-sdk-for-net_tmp/generateOutput.json
    • ️✔️Azure.Messaging.EventGrid.Namespaces [View full logs]  [Preview SDK Changes]
      info	[Changelog]
    Posted by Swagger Pipeline | How to fix these errors?

    @openapi-pipeline-app
    Copy link

    openapi-pipeline-app bot commented May 19, 2023

    Generated ApiView

    Language Package Name ApiView Link
    Python azure-eventgrid https://apiview.dev/Assemblies/Review/449f7d3353214a83b222ebe1f130c9a9
    .Net Azure.Messaging.EventGrid.Namespaces https://apiview.dev/Assemblies/Review/b41728707fa24db28b02680f4afa74fc

    @ghost ghost added the Event Grid label May 19, 2023
    @doc("Max wait time value for receive operation in Seconds. It is the time in seconds that the server approximately waits for the availability of an event and responds to the request. If an event is available, the broker responds immediately to the client. Minimum value is 10 seconds, while maximum value is 120 seconds. If not specified, the default value is 60 seconds.")
    @encode("seconds", int32)
    @query
    maxWaitTime?: int32 = 60;
    Copy link
    Member Author

    @l0lawrence l0lawrence May 22, 2023

    Choose a reason for hiding this comment

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

    def function(max_wait_time: string or whatever a duration is)

    In the background should be sending as an int -- should serialize it to an int across the wire

    @lmazuel lmazuel marked this pull request as ready for review May 22, 2023 17:53
    @lmazuel lmazuel requested review from Kishp01 and ahamad-MS as code owners May 22, 2023 17:53
    @lmazuel lmazuel merged commit d1c21b5 into Azure:feature/eventgrid/typespec May 22, 2023
    lmazuel added a commit that referenced this pull request May 22, 2023
    * start typespec
    
    * adding eventgrid typespec for api w/ TODOs
    
    * update eventgrid typespec with latest eventgrid v2 operations
    
    * don't require content-type if there is no body
    
    * Update specification/eventgrid/typespec/main.tsp
    
    Co-authored-by: JoshLove-msft <54595583+JoshLove-msft@users.noreply.github.com>
    
    * Update specification/eventgrid/typespec/main.tsp
    
    Co-authored-by: JoshLove-msft <54595583+JoshLove-msft@users.noreply.github.com>
    
    * changing naming of cloudevent and added in data_base64
    
    * openapi.json
    
    * Update specification/eventgrid/typespec/main.tsp
    
    Co-authored-by: Libba Lawrence <llawrence@microsoft.com>
    
    * Update specification/eventgrid/typespec/main.tsp
    
    Co-authored-by: Libba Lawrence <llawrence@microsoft.com>
    
    * Update specification/eventgrid/typespec/main.tsp
    
    Co-authored-by: Libba Lawrence <llawrence@microsoft.com>
    
    * lockTokens format, updated json, optional? params
    
    * address code review comments
    
    * name_change
    
    * add @internal for python
    
    * Update specification/eventgrid/Azure.Messaging.EventGrid/main.tsp
    
    Co-authored-by: JoshLove-msft <54595583+JoshLove-msft@users.noreply.github.com>
    
    * move @internal to client.tsp (#23538)
    
    * rename (#23565)
    
    * [EventGrid Typespec] breaking changes with april release of typespec (#23539)
    
    * breaking changes with april release of typespec
    
    * unknown type
    
    * [EG Typespec] Update Release behavior (#23699)
    
    * update behavior
    
    * just behavior
    
    * Add tspconfig and remove AAD auth (#23717)
    
    * add tspconfig
    
    * add namespace
    
    * remove oauth
    
    * [EG TypeSpec] Archboard Comments (#23696)
    
    * refactoring off of apiview
    
    * keep as int
    
    * no duration
    
    * aligning ack and release
    
    * remove behavioral change
    
    * ack to release
    
    * initial naming changes
    
    * Update ReleaseResult doc
    
    Co-authored-by: JoshLove-msft <54595583+JoshLove-msft@users.noreply.github.com>
    
    * Update AckResult doc
    
    Co-authored-by: JoshLove-msft <54595583+JoshLove-msft@users.noreply.github.com>
    
    * versioning twice-- remove one instance
    
    ---------
    
    Co-authored-by: JoshLove-msft <54595583+JoshLove-msft@users.noreply.github.com>
    
    * Address couple of stewardship team feedback. These include: 1. Rename CloudEventEvent to simply CloudEvent, 2. Add more description to the operations including the possible erorr codes, 3. Add PublishResult with empty Json object as successful response for the Publish operation, 4. Others.
    
    * Add support for missing Reject operation + adding deliveryAttemptCount to BrokerProperties + Adding query parameter for release operation for deliveryDelayInSeconds
    
    * Update failedTokens/SuccessfulTokens Description to address code review comments
    
    * Update to match service behavior (#23754)
    
    * Update to match service behavior
    
    * remove locktoken
    
    * [EGv2] Editing unused variables (#23917)
    
    * event delivery delay not in preview
    
    * remove from url comment
    
    * [EGv2] Version dependency on Azure.Core  (#23936)
    
    * verioning fix
    
    * spacing mishap?
    
    * [EventGrid] Deliveryattempt change (#23960)
    
    * deliveryCount 5/1
    
    * small typo
    
    * [EventGrid] Remove internal (#23995)
    
    * remove internal
    
    * remove client.tsp
    
    * remove waitWaitTime (#24078)
    
    * move location of json file (#24076)
    
    * [Egv2] Encode param (#24080)
    
    * encode
    
    * remove num default on duration
    
    ---------
    
    Co-authored-by: Laurent Mazuel <laurent.mazuel@gmail.com>
    
    * [EGv2] Fix pipeline (#24098)
    
    * regen off new commit for encode
    
    * reference preview tag
    
    * ignore word
    
    * update readme to have both apis
    
    * update with next autorest
    
    * change format to int32
    
    ---------
    
    Co-authored-by: Ashraf Hamad <ahamad@ntdev.microsoft.com>
    Co-authored-by: Laurent Mazuel <laurent.mazuel@gmail.com>
    Co-authored-by: JoshLove-msft <54595583+JoshLove-msft@users.noreply.github.com>
    Co-authored-by: Ashraf Hamad <ahamad-MS@users.noreply.github.com>
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

    Projects

    None yet

    Development

    Successfully merging this pull request may close these issues.

    2 participants