Skip to content

Commit

Permalink
Merged from main
Browse files Browse the repository at this point in the history
  • Loading branch information
ErikMogensen committed Feb 13, 2024
2 parents 22ca39d + 27ba8a6 commit 522bcd5
Show file tree
Hide file tree
Showing 19 changed files with 485 additions and 710 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
name: Build and run unit tests
runs-on: windows-2022
env:
NUnitVersion: '3.15.2'
NUnitVersion: '3.16.3'
steps:
- name: Install NUnit Console Runner and VS project extension
run: |
Expand Down
8 changes: 8 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,14 @@ The default location of the executable is C:\ProgramData\chocolatey\lib\ServiceB

More information on our [Chocolatey page](https://chocolatey.org/packages/ServiceBusExplorer).

## Using [Scoop](https://scoop.sh)

```
scoop install extras/servicebusexplorer
```

The default location of the executable is %USERPROFILE%\scoop\apps\servicebusexplorer\current\tools\ServiceBusExplorer.exe.

## Using GitHub
```
curl -s https://api.github.com/repos/paolosalvatori/ServiceBusExplorer/releases/latest | grep browser_download_url | cut -d '"' -f 4
Expand Down
4 changes: 1 addition & 3 deletions src/Common/Common.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,8 @@
<ItemGroup>

<PackageReference Include="Microsoft.Azure.NotificationHubs" Version="1.0.9" />
<PackageReference Include="Microsoft.Azure.Relay" Version="2.0.15596" />
<PackageReference Include="Newtonsoft.Json" Version="13.0.1" />

<PackageReference Include="WindowsAzure.ServiceBus" Version="6.2.2" />
<PackageReference Include="WindowsAzure.ServiceBus" Version="7.0.1" />
</ItemGroup>
<ItemGroup>
<Reference Include="System.Configuration" />
Expand Down
20 changes: 16 additions & 4 deletions src/Common/Helpers/DeadLetterMessageHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,8 @@ public DeadLetterMessageHandler(WriteToLogDelegate writeToLog, ServiceBusHelper
#endregion

#region Public methods
public async Task<DeletedDlqMessagesResult> DeleteMessages(List<long?> sequenceNumbers)
public async Task<DeletedDlqMessagesResult> DeleteMessages(List<long?> sequenceNumbers,
bool TransferDLQ)
{
var sequenceNumbersToDeleteList = new List<long?>();
foreach (var number in sequenceNumbers)
Expand All @@ -96,7 +97,7 @@ public async Task<DeletedDlqMessagesResult> DeleteMessages(List<long?> sequenceN
}

var timedOut = false;
var dlqEntityPath = GetDlqEntityPath();
var dlqEntityPath = TransferDLQ ? GetTransferDlqEntityPath() : GetDlqEntityPath();

var messageReceiver = await serviceBusHelper.MessagingFactory.CreateMessageReceiverAsync(
dlqEntityPath,
Expand Down Expand Up @@ -185,7 +186,7 @@ public async Task<DeletedDlqMessagesResult> DeleteMessages(List<long?> sequenceN


public async Task<DeletedDlqMessagesResult> MoveMessages(MessageSender messageSender,
List<long> sequenceNumbers, List<BrokeredMessage> messagesToSend = null)
List<long> sequenceNumbers, bool transferDLQ, List<BrokeredMessage> messagesToSend = null)
{
if (messagesToSend != null)
{
Expand All @@ -196,7 +197,7 @@ public async Task<DeletedDlqMessagesResult> MoveMessages(MessageSender messageSe
}
}

var dlqEntityPath = GetDlqEntityPath();
var dlqEntityPath = transferDLQ ? GetTransferDlqEntityPath() : GetDlqEntityPath();

var messageReceiver = serviceBusHelper.MessagingFactory.CreateMessageReceiver(
dlqEntityPath,
Expand Down Expand Up @@ -368,6 +369,17 @@ string GetDlqEntityPath()
sourceSubscriptionWrapper.SubscriptionDescription.TopicPath,
sourceSubscriptionWrapper.SubscriptionDescription.Name);
}

string GetTransferDlqEntityPath()
{
if (sourceQueueDescription != null)
{
return QueueClient.FormatTransferDeadLetterPath(sourceQueueDescription.Path);
}

throw new Exception("It is currently not supported getting a Transfer Dead-letter queue for a subscription.");
}

void WriteToLog(string message)
{
if (writeToLog != null && !string.IsNullOrWhiteSpace(message))
Expand Down
2 changes: 1 addition & 1 deletion src/EventHubs/EventHubs.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@


<ItemGroup>
<PackageReference Include="Azure.Messaging.EventHubs" Version="5.7.3" />
<PackageReference Include="Azure.Messaging.EventHubs" Version="5.10.0" />
</ItemGroup>


Expand Down
2 changes: 1 addition & 1 deletion src/NotificationHubs/NotificationHubs.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Microsoft.Azure.NotificationHubs" Version="1.0.9" />
<PackageReference Include="Newtonsoft.Json" Version="13.0.1" />
<PackageReference Include="Newtonsoft.Json" Version="13.0.3" />
</ItemGroup>
<ItemGroup>
<Reference Include="System.ServiceModel" />
Expand Down
2 changes: 1 addition & 1 deletion src/Relay/Relay.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@


<ItemGroup>
<PackageReference Include="Microsoft.Azure.Relay" Version="2.0.15596" />
<PackageReference Include="Microsoft.Azure.Relay" Version="3.0.1" />
</ItemGroup>


Expand Down
2 changes: 1 addition & 1 deletion src/ServiceBus/ServiceBus.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@


<ItemGroup>
<PackageReference Include="Azure.Messaging.ServiceBus" Version="7.11.0" />
<PackageReference Include="Azure.Messaging.ServiceBus" Version="7.17.0" />
</ItemGroup>


Expand Down
6 changes: 3 additions & 3 deletions src/ServiceBusExplorer.Tests/ServiceBusExplorer.Tests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@
<ProjectReference Include="..\Utilities\Utilities.csproj" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="NUnit" Version="3.13.3" />
<PackageReference Include="NUnit3TestAdapter" Version="4.4.2" />
<PackageReference Include="WindowsAzure.ServiceBus" Version="6.2.2" />
<PackageReference Include="NUnit" Version="3.14.0" />
<PackageReference Include="NUnit3TestAdapter" Version="4.5.0" />
<PackageReference Include="WindowsAzure.ServiceBus" Version="7.0.1" />
</ItemGroup>
</Project>
Loading

0 comments on commit 522bcd5

Please sign in to comment.