elbandit / pppddd Goto Github PK
View Code? Open in Web Editor NEWSample code for the book Principles, Practices and Patterns of Domain-Driven Design
Sample code for the book Principles, Practices and Patterns of Domain-Driven Design
@elbandit I bought your design patterns book from amazon and i learned a lot from it as specially from case study parts, i honestly can say that i learned everything that about desing patters from you, really a big thanks! I was thinking over buyin your this book too but before buying I would like to check it out to make desicion but i couldnt see casestudy(very important!!) and cqrs(i do want to learn it from you!!) projects on here, is there anything im missing or you have a privacy plan?
var orderCreatedEvent = new Sales.Messages.Events.OrderCreated_V2
{
OrderId = orderId,
UserId = message.UserId,
ProductIds = message.ProductIds,
ShippingTypeId = message.ShippingTypeId,
TimeStamp = DateTime.Now,
Amount = CalculateCostOf(message.ProductIds),
AddressId = "AddressID123"
};
try
{
Bus.Publish(orderCreatedEvent);
}
catch (HttpRequestException e)
{
// Handle exception.
}
e.InnerException = {"Unable to connect to the remote server"}
The code for chapter 8 is nowhere to be found. Neither here nor on the website.
The code listed in Chapter 12 has many errors, such as typos and wrong project, namespace, type and member names (one name appears in the listing, a different one in the body text).
Besides, I can't get PaymentAccepted to work—and, consequently, nothing beyond this point.
I tried the downloaded code, to see how things should work, but it throws exceptions, which I don't know how to handle...
I'm very disappointed at the low quality of this book. The experience is quite frustrating. I want to learn, but this book won't allow me.
An exception of type 'System.Configuration.ConfigurationErrorsException' occurred in NServiceBus.Core.dll but was not handled in user code
Web.config:-
<configSections>
<section name="MessageForwardingInCaseOfFaultConfig"
type="NServiceBus.Config.MessageForwardingInCaseOfFaultConfig,
NServiceBus.Core" />
</configSections>
[HttpPost]
public ActionResult Place(string userId, string productIds, string shippingTypeId)
{
var realProductIds = productIds.Split(',');
var placeOrderCommand = new PlaceOrder
{
UserId = userId,
ProductIds = realProductIds,
ShippingTypeId = shippingTypeId,
TimeStamp = DateTime.Now
};
MvcApplication.Bus.Send("Sales.Orders.OrderCreated", placeOrderCommand);
return Content("Your order has been placed. You will receive email confirmation shortly.");
}
I am getting the exception at Bus.Send line.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.