-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
78 changed files
with
3,256 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
using System.Threading.Tasks; | ||
using NServiceBus; | ||
using NServiceBus.Logging; | ||
|
||
class AuthorizeTransactionResponseHandler : | ||
IHandleMessages<AuthorizeTransactionResponse> | ||
{ | ||
public Task Handle(AuthorizeTransactionResponse message, IMessageHandlerContext context) | ||
{ | ||
log.Info($"Payment transaction for order {message.OrderId} authorized."); | ||
|
||
return context.Publish(new PaymentCompleted | ||
{ | ||
OrderId = message.OrderId | ||
}); | ||
} | ||
|
||
static ILog log = LogManager.GetLogger<OrderAcceptedHandler>(); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
<Project Sdk="Microsoft.NET.Sdk"> | ||
<PropertyGroup> | ||
<TargetFramework>net461</TargetFramework> | ||
<OutputType>Exe</OutputType> | ||
<LangVersion>7.1</LangVersion> | ||
</PropertyGroup> | ||
<ItemGroup> | ||
<ProjectReference Include="..\NServiceBus.Router.Migrator\NServiceBus.Router.Migrator.csproj" /> | ||
<ProjectReference Include="..\Shared\Shared.csproj" /> | ||
<PackageReference Include="NServiceBus.SqlServer" Version="5.*" /> | ||
<PackageReference Include="NServiceBus.Transport.Msmq" Version="1.*" /> | ||
</ItemGroup> | ||
</Project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
using System.Threading.Tasks; | ||
using NServiceBus; | ||
using NServiceBus.Logging; | ||
|
||
class OrderAcceptedHandler : | ||
IHandleMessages<OrderAccepted> | ||
{ | ||
public Task Handle(OrderAccepted message, IMessageHandlerContext context) | ||
{ | ||
log.Info($"Attempting to authorize the payment transaction for order {message.OrderId}."); | ||
|
||
return context.Send(new AuthorizeTransaction | ||
{ | ||
OrderId = message.OrderId | ||
}); | ||
} | ||
|
||
static ILog log = LogManager.GetLogger<OrderAcceptedHandler>(); | ||
} |
Oops, something went wrong.