Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DOCUMENTATION: Add Dead-End Services #233

Open
LBoullosa opened this issue Feb 4, 2023 · 3 comments
Open

DOCUMENTATION: Add Dead-End Services #233

LBoullosa opened this issue Feb 4, 2023 · 3 comments

Comments

@LBoullosa
Copy link
Contributor

There is no documentation about Dead-End Services.
I asked this on Discord channel,

which name should be the right one for a dead-end service?
Where should be located under the project? ProcessingServices, Foundations.....

Response from @hassanhabib as a brief explanation,

It depends on the type of work that dead-end service does. It can be Processing and it can be Foundation - usually dead-end services tend to do something a bit more advanced so they live in the Processing layers. But every now and then they do something very basic like Add or Subtract in a calculator - they become immediately Foundation.

@hassanhabib
Copy link
Owner

We need to solve for internal mocking. We need a mechanism that is easy to override the implementation of a deadend function and replace it with an exception.
So far we have InternalMock from here.
However the solution seems incomplete - we started seeing issues due to reflection.

cc: @cjdutoit

@LBoullosa
Copy link
Contributor Author

I see a drawback with dead-end services since it could be used/integrated by other services, it could turn into a common/helper service. Any thoughts about this @hassanhabib?

@hassanhabib
Copy link
Owner

hassanhabib commented Mar 13, 2023

I see a drawback with dead-end services since it could be used/integrated by other services, it could turn into a common/helper service. Any thoughts about this @hassanhabib?

@LBoullosa If it stays within it's own domain. with one single model/contract and a very specific responsibility. I think it might not be an issue. The issue with commons and helpers is that they are chaos. No common contracts, no single responsibility. They're all over the place.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants