Closed henryz0113 closed 1 year ago
That's not good....
I compared the code in 5.0.3 with 5.0.7 and I see that WindowsAzure.ServiceBus was upgraded from 6.0.3 to 6.2.0. Are you able to build the solution? In that case, please downgrade the latest source code to use WindowsAzure.ServiceBus 6.0.3 and test if you can reproduce the issue.
Hi @ErikMogensen I don't know if this is the right way to do it but I've overwritten the Microsoft.ServiceBus.dll from 5.0.3 to the 5.0.15 And I am able to see the messages on the 5.01.15.
However, I am not to sure what are the impacts of changing this. Would this be the correct way to do so?
Thanks
Good that you found the issue. There may be other bugs or missing features in the older version. You can look at the Release notes for the later releases, for instance Release note for WindowsAzure.ServiceBus 6.2.0. I suggest you keep using that version.
The best thing would be if you created a case with Microsoft and asked them to fix the bug. However, I believe they will be reluctant to fix it and instead suggest a switch to the other SDK for Event hubs. But It is not possible to switch ServiceBusExplorer to that SDK since it is lacking support for managing Event hubs using connection strings.
Thanks @ErikMogensen. I'll check with Microsoft on this.
I have had a similar problem reading Event messages with V-5.0.15 (and every version after V-5.0.4). On advice from @ErikMogensen, I replaced Microsoft.ServiceBus.dll with the version used in V-5.0.4 which has resolved my problem. Thanks.
I've looked into what's happening, and it appears to be a breaking change with WindowsAzure.ServiceBus. SBE relies on the public API to clone an EventData
using EventData.Clone()
, but the underlying implementation has been changed, and now the exception is thrown.
at Microsoft.ServiceBus.Common.ReadOnlyDictionary45`2.System.Collections.Generic.IDictionary.set_Item(TKey key, TValue value) in Microsoft.ServiceBus.Common\ReadOnlyDictionary45.cs:line 308
at Microsoft.ServiceBus.Messaging.EventData.UpdateUserPropertiesForReceive() in Microsoft.ServiceBus.Messaging\EventData.cs:line 303
at Microsoft.ServiceBus.Messaging.EventData.Clone() in Microsoft.ServiceBus.Messaging\EventData.cs:line 246
at ServiceBusExplorer.Controls.PartitionListenerControl.eventDataDataGridView_RowEnter(Object sender, DataGridViewCellEventArgs e) in C:\github\SeanFeldman\ServiceBusExplorer\src\ServiceBusExplorer\Controls\PartitionListenerControl.cs:line 647
This is also the case for the Properties
property of EventData
.
Some more analysis of the code path for EventHubs shows that the approach taken for both BrokeredMessage
and EventData
was storing the original messages in the grid, and whenever a specific one would be selected, it would be cloned for manipulations such as stream and properties reading to populate the selected message UI controls. With the Clone method broken, the implementation doesn't hold and would require reading messages once only, storing some abstraction that would allow "cloning"/working with the event body.
For Properties
, I'm not sure what the solution is since SDK is throwing, and we have no access to those.
Properties
is working fine.
@henryz0113, a potential workaround w/o downgrading the SDK is coming.
Hey @SeanFeldman thank you for the update! 💯
@henryz0113, you can check out the branch and give it a try. I'm not a frequent EH user to validate SBE change. If you could do that and post your findings, it would help. Thank you.
Hey @SeanFeldman awesome job!! Looking great!
We can pick up every information! @ErikMogensen can you please double check and merge it as well?
Hi Guys, Appreciate the work you guys put into the explorer. It really does make life easy. However, I found an issue while testing the in-bult send and listen function to view the message.
[Summary] I tried sending, receiving and reading messages through the built-in function as I wanted to see if the messages are going through fine. The message is sent and received fine but, the issue with reading the messages that was sent.
The functions used within the explorer are
Send Event
/Create Partition Listener
[Issue] The issue appears from
5.0.7
, the version I had, and also updated to newest5.0.15
, and the issue is still appearing as well.When sending the message I can see an Exception returning from the activity log.
Exception : This object is read-only and cannot be modified.
This message also appears on theproperties
ofEvent System Properties
when viewed from the Listener popup console.Also you can
Event Custom Properties
is blank, where it should have themachine name
and theuser name
.[TroubleShooting / Validating] I have validated that with version
5.0.3
, we are able to send and receive the test message and be able to read the test message sent.From this image, you can see that the
properties
is blank without the exception. As well as, theEvent Custom Properties
hasmachine name
anduser name
filled up.Could you please fix this issue? Thank you in advance.