3

Is there any sort of concept in DDD related to an "Application Gateway"?

I'm defining an "Application Gateway" as an API layer (REST, GraphQL, etc.) that provides a single interface for clients to interact with.

This would be in contrast to the client talking to the application layer for each bounded context.

This approach would require the "Application Gateway" to interact with multiple bounded contexts which seems like it may violate DDD in some way.

Is there anything like this in DDD? Is this not a DDD concern?

3

This is outside the DDD concern. If you correctly identify the bounded contexts and the Aggregate boundaries, if your Domain layer is pure (no side effects) with no dependencies to Infrastructure or Presentation then how you call it is no DDD concern.

In other words, you can have any kind of client for the Domain layer, in any architecture.

This approach would require the "Application Gateway" to interact with multiple bounded contexts which seems like it may violate DDD in some way.

Why? This is how well designed/modularized monoliths work. It may not be well suited for a microservice architecture, at the system level, as a microservice should not be larger than a Bounded context.

  • Could my explanation of an "Application Gateway" be or be similar to an anti-corruption layer? – anthonator Jan 5 '18 at 20:21
  • 1
    Your "application gateway" is in fact a Presentation layer – Constantin Galbenu Jan 5 '18 at 20:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.