Should I unite business domains into one business layer

74 views Asked by At

I'm redesigning our company's existing BL+DAL. Today it is a single dll, directly referenced and is tightly coupled. I'm thinking about a service architecture that would give its services to several UI applications.

I heard about SOA and DDD but could not find any detail sample design.I'm not quite sure about how would be best to divide the components between my assemblies. My options:

  1. One assembly per domain that includes [Service Layer - BL - DAL]
  2. One assembly of Service Layer, one per domain of BL , and one per domain of DAL
  3. One assembly per layer : All Service assembly , all BL assembly , all Dal. Not quite sure this is even SOA

also: Can I call from one domain BL to another domain DAL?

Thanks

1

There are 1 answers

0
Yugang Zhou On

I prefer the first one.

One assembly of Service Layer, one per domain of BL , and one per domain of DAL.

Low cohesion. The team usually need to modify all three layers to complete one task.

One assembly per layer : All Service assembly , all BL assembly , all Dal. Not quite sure this is even SOA

High coupling. Different domain may have different release frequency, now it task extra cost to achieve it. For example, branches.

You need take more architecture constraints to make the decision, not only DDD.