Prevent SonarCloud cross-boundary duplication scans for dotnet core CQRS?

Hi there,

We are currently running a solution broken down into multiple project structures, and using CQRS.
E.g.

|- ROOT
  |- BoundedContextA - Solution folder
    |- API - Project
    |- Application - Project
    |- Infrastructure - Project
    |- Domain - Project
    |- Core - Project

When SonarCloud scans CPD, it’s currently detecting duplication issues between API request models and Application request models.
I believe this violates the SRP between the project scope as it makes some assumptions about how dotnet projects should be structured regardless of any architectural pattern adopted.

Is there a way to reduce this forced coupling and disable cross-boundary CPD scans?

Please let me know if I should provide more information or if something isn’t clear.

Thanks and kind regards,
Chris

Hi Chris,

Welcome to the community!

Not as such.

I think the best thing to do here is set a duplications exclusion on either API or Application.

 
HTH,
Ann