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.01k stars 584 forks source link

When resubmitting a block of messages all the properties are lost #84

Closed MikeWilliams-UK closed 7 years ago

MikeWilliams-UK commented 7 years ago

Scenario Receive a block of messages Select them all, then Right Click Repair and Resubmit Select body type of string

All messages which are re-submitted loose ALL of their properties.

As a temporary fix I have commented out line 354 of MessageForm.cs [inside btnSubmit_Click()] //outboundMessage.Properties.Clear();

I know this is probably not ideal but it works for us.

A better solution would be to have an option to preserve properties except the two dead letter ones?

MikeWilliams-UK commented 7 years ago

Related to https://github.com/paolosalvatori/ServiceBusExplorer/issues/79

SeanFeldman commented 7 years ago

@MikeWilliams-UK the two DLQ related properties are filtered out anyways.

@paolosalvatori why was outboundMessage.Properties.Clear(); needed?

MikeWilliams-UK commented 7 years ago

@SeanFeldman I only mentioned the DLQ properties for completeness. In our case we are shifting a block of messages from a DLQ onto another queue to re-reprocess them. In this case it is critical that all of the original properties are sent to the other queue.

paolosalvatori commented 7 years ago

Hi @MikeWilliams-UK I fixed the problem, please pick up the latest version and let me know if it works as expected. I basically eliminates the line of code that you removed from the MessageForm.cs [inside btnSubmit_Click()] method.

MikeWilliams-UK commented 7 years ago

@paolosalvatori I have downloaded the latest version and it won't compile

Error CS0115 'MainForm.Dispose(bool)': no suitable method found to override ServiceBusExplorer Error CS0246 The type or namespace name 'HeaderPanel' could not be found (are you missing a using directive or an assembly reference?) Error CS0246 The type or namespace name 'HeaderPanel' could not be found (are you missing a using directive or an assembly reference?) Error CS0246 The type or namespace name 'HeaderPanel' could not be found (are you missing a using directive or an assembly reference?)

MikeWilliams-UK commented 7 years ago

@paolosalvatori I have downloaded the latest version and it won't compile VS2015 Update 3

paolosalvatori commented 7 years ago

Fixed, the problem was due to the fact that I changed the namespace of classes, but when I synchronized my commit, I had to merge changes made by @SeanFeldman that still contained the old namespace.

paolosalvatori commented 7 years ago

@SeanFeldman this is a major release as the tool now uses Microsoft.ServiceBus.dll v.4.0. Could you please change the major release number from 3 to 4? Thanks!

MikeWilliams-UK commented 7 years ago

Thanks @paolosalvatori the latest version works fine and fixes our issue.

SeanFeldman commented 7 years ago

@paolosalvatori can be done as part of a commit. AppVeyor.yaml has the info to update here. I'll do it on the master.

SeanFeldman commented 7 years ago

4.0.x is up.

paolosalvatori commented 7 years ago

Thanks @SeanFeldman!

mrpmorris commented 5 years ago

Hi @MikeWilliams-UK I fixed the problem, please pick up the latest version and let me know if it works as expected. I basically eliminates the line of code that you removed from the MessageForm.cs [inside btnSubmit_Click()] method.

@paolosalvatori I am seeing this problem in 4.1.112

ErikMogensen commented 5 years ago

I just tried this and it worked. Please describe which steps you do to reproduce this.

mrpmorris commented 5 years ago

@ErikMogensen 1: Go to Dead Letter Queue 2: Peek 999 3: Sort by date (descending) 4: Right-click (Repair and resubmit) 5: Format = string, Generate a new ID 6: Select the same queue and submit it 7: (I think the resubmit window stays open here, if I recall correctly then close it so the queues refresh)

It's possible that the contents only appear as a null string. I think I saw valid data in my logs once but the dead-lettered message appeared to be blank in the UI.

ErikMogensen commented 5 years ago

@mrpmorris , that works for me. To my surprise the DeadLetter properties were also copied which I did not think was possible.

I wonder if this could have to do with the content of the messages. Please try again just using plain strings as message content. As you probably know you can easily create a lot of messages by right-clicking a queue and select Send messages.

ErikMogensen commented 5 years ago

Moved the latest two posts to #84.