paolosalvatori / ServiceBusExplorer

The Service Bus Explorer allows users to connect to a Service Bus namespace and administer messaging entities in an easy manner. The tool provides advanced features like import/export functionality or the ability to test topic, queues, subscriptions, relay services, notification hubs and events hubs.
MIT License
2.02k stars 588 forks source link

Event Grid Explorer - Adding Support for Event Grid V2 #737

Closed t-wangamy closed 5 months ago

t-wangamy commented 1 year ago

For my Summer 2023 internship project under the Azure Messaging Event Grid team, I developed the Event Grid Explorer. This is a tool integrated in Service Bus Explorer for viewing and managing Event Grid V2 entities, including namespaces, topics and subscriptions, as well as provide create/delete operations for topics and subscriptions, publish/receive operations for events, and acknowledge/release/reject operations for events.

Currently, the Event Grid Explorer features the functionality that is available for the preview version of Event Grid V2. This additional support for Event Grid V2 enables users to test event delivery with ease, contributing to the adoption of the new service.

The modifications include creating new Controls and Forms under ServiceBusExplorer as well as implementing an EventGridExplorerLibrary to interact with the Event Grid V2 SDK functions. This library also contains additional files under the Management folder that set up Event Grid related objects.

t-wangamy commented 1 year ago

@SeanFeldman Today is actually the last day of my internship so I pushed the last changes for the Event Grid Explorer README. Thank you for reviewing my work and for your helpful feedback! I think from here my team will help with making any additional changes

SeanFeldman commented 1 year ago

@SeanFeldman Today is actually the last day of my internship so I pushed the last changes for the Event Grid Explorer README. Thank you for reviewing my work and for your helpful feedback! I think from here my team will help with making any additional changes

@t-wangamy, thank you so much for the contribution. I'll work on bringing it to the merge point. Please let me know who can continue from your team. Maybe tag them here.

Thank you and good luck!

hillaryc commented 1 year ago

@SeanFeldman Today is actually the last day of my internship so I pushed the last changes for the Event Grid Explorer README. Thank you for reviewing my work and for your helpful feedback! I think from here my team will help with making any additional changes

@t-wangamy, thank you so much for the contribution. I'll work on bringing it to the merge point. Please let me know who can continue from your team. Maybe tag them here.

Thank you and good luck!

Hi @SeanFeldman, I will continue.

SeanFeldman commented 1 year ago

@hillaryc, great!

would you be able to review the two remaining questions? Thank you.

SeanFeldman commented 1 year ago

@hillaryc, would you be able to assist with the questions/clarifications? I'd like to wrap up the PR. Thank you for your help.

hillaryc commented 1 year ago

Yes, I will work on this today. 😊 Best Regards, Hillary

From: Sean Feldman @.> Sent: Friday, September 22, 2023 8:26 AM To: paolosalvatori/ServiceBusExplorer @.> Cc: Hillary Caituiro Monge @.>; Mention @.> Subject: Re: [paolosalvatori/ServiceBusExplorer] Event Grid Explorer - Adding Support for Event Grid V2 (PR #737)

@hillarychttps://github.com/hillaryc, would you be able to assist with the questions/clarifications? I'd like to wrap up the PR. Thank you for your help.

— Reply to this email directly, view it on GitHubhttps://github.com/paolosalvatori/ServiceBusExplorer/pull/737#issuecomment-1731611113, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AT3VM5QA4PB43M5AUAFPOP3X3WUZZANCNFSM6AAAAAA3THR3GQ. You are receiving this because you were mentioned.Message ID: @.**@.>>

SeanFeldman commented 1 year ago

Yes, I will work on this today. 😊

Thank you, @hillaryc.

hillaryc commented 1 year ago

I believe I replied all questions :) Let me know if anything. @SeanFeldman

hillaryc commented 1 year ago

Hi @SeanFeldman, let me know if there is anything pending to be done to merge this.

SeanFeldman commented 1 year ago

@hillaryc, code-wise, except for the lack of information on how to regenerate the auto-generated code, the rest is OK. These are the issues I've run into while manually testing the branch.

  1. API version - there's no default and no dynamic selector to allow users to choose from something. I suggest putting a default. I've used 2023-06-01-preview. image

  2. Multi-tenant users - I have multiple tenants and subscriptions. There's no way to indicate what tenant should be used. I've failed to log into the subscription I've provided the information for in the login/credentials screen.

Error message (redacted)

Exception: The access token is from the wrong issuer 'https://sts.windows.net/xxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx/'. It must match the tenant 'https://sts.windows.net/yyyyyy-yyyy-yyyy-yyyy-yyyyyyyyyy/' associated with this subscription. Please use the authority (URL) 'https://login.windows.net/yyyyyy-yyyy-yyyy-yyyy-yyyyyyyyyy' to get the token. Note, if the subscription is transferred to another tenant there is no impact to the services, but information about new tenant could take time to propagate (up to an hour). If you just transferred your subscription and see this error message, please try back later.

The last issue is a blocker. Since there's no simple connection string and the only way to connect is to provide resource group, subscription ID, and the EG namespace (in addition to the API version), it's unclear how to troubleshoot the connectivity when an error such as this is encountered.

SeanFeldman commented 1 year ago

@hillaryc, something is off about this PR.

  1. It took several subscriptions to connect to a namespace.
  2. When creating subscriptions, there's no way to provide filters. Those cannot be updated later either and require Azure Portal.
  3. I was unsuccessful in following the documentation to publish and receive an event.

I'll merge the PR, but further work is required, I suspect.

cc @paolosalvatori @ErikMogensen

ErikMogensen commented 1 year ago

I was also unable to connect to a Event Grid namespace using a Microsoft account. It worked using a work account.

I agree about it would be useful to know how the autogenerated files were created since the service API will likely change in the future.

SeanFeldman commented 1 year ago

Status update

The PR is returning to a draft mode to address usability and maintainability. In addition to that, there will be an effort to transition off auto-generated code to the Azure SDK and the ability to add/alter subscription filters, which is essential for working with EG v2.

harrieoriowo commented 5 months ago

I believe I am done-done. I have opened it for final review!

SeanFeldman commented 5 months ago

@harrieoriowo, overall, looks good. Once you're done with the last review comments, I'm 👍 to merge. Thank you.