Skip to content

[Question] Isn't the Eventual Consistency Middleware coupling Infrastructure to Presentation? #31

Description

@Thijs153

Hi @amantinband,

I have a question concerning the Eventual Consistency Middleware.

By implementing an Eventual Consistency Middleware in the infrastructure layer that relies on the HttpContext, you are, in a sense, creating a dependency on a specific presentation mechanism (ASP.NET Core's HTTP handling), i.e. coupling the infrastructure layer with the presentation layer.

If you decide to switch the presentation layer technology (e.g., to a Blazor server application), this will break because there isn't a valid HttpContext available.

What are your thoughts/views about this? I could be wrong, so please correct me if I'm mistaken.
Would something like the Outbox pattern be a solution for this?

P.S. This may be unrelated here, but are you ever planning on making a video about the Event Patterns you can implement for scenarios where event 1 sends a success email but event 2 fails, and how to tackle these challenges?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions