In Domain Driven Design, can services call other services?
Date : March 29 2020, 07:55 AM
around this issue Is your question about Domain Services, not application or infrastructure services? If so, DDD has no specific guidelines about isolating Domain Services from each other. Use your judgement and watch for SOLID violations. Also keep in mind that domain services are often misused and it makes sense to put more logic into Entities:
|
How should Domain Services call Infrastructure services?
Date : March 29 2020, 07:55 AM
it fixes the issue 1a) An IS can be injected into a domain service if it needs it for functionality - ie not passed to method. This is different than entities and it is because a domain service is stateless and so it can be configured with required dependencies once and used where needed, such as by other entities. 1b) A domain service should be passed to entity as argument much like you would pass a repository interface as argument. The same principles apply. Also, passing entire repository interface can create needless coupling and so it is better to declare and pass a role specific interface.
|
Why does No 'Access-Control-Allow-Origin' is not enforced when I call third party services, but it is when I call my own
Date : March 29 2020, 07:55 AM
Hope this helps At first I thought it was a problem with my server configuration var origin, method, headers;
origin = getRequestHeader("Origin");
if (origin /* and you want to grant access to it */) {
addResponseHeader("Access-Control-Allow-Origin", origin);
method = getRequestHeader("Access-Control-Request-Method");
if (method) {
// Note the request header is singular, but the response header is plural
addResponseHeader("Access-Control-Allow-Methods", method);
}
headers = getRequestHeader("Access-Control-Request-Headers");
if (headers) {
addResponseHeader("Access-Control-Allow-Headers", headers);
}
if (/* You want to allow the origin to provide credentials and cookies*/) {
addResponseHeader("Access-Control-Allow-Credentials", "true");
}
}
|
Ambiguous call services.AddOptions() in ConfigureServices(IServiceCollection services)
Date : March 29 2020, 07:55 AM
it should still fix some issue Based on the feedback from this question I tracked down that I had a reference in project.lock.json to "EntityFramework.MicrosoftSqlServer": "7.0.0-rc1-final" which on its own has a reference to "Microsoft.Extensions.OptionsModel": "1.0.0-rc1-final" The whole point is to have only references to "Microsoft.Extensions.Options": "1.0.0-rc2-final" and remove all the ones to OptionsModel.
|
Keystore configuration for calling services that call other services with different sets of certificates
Tag : java , By : Julian Ivanov
Date : March 29 2020, 07:55 AM
wish helps you It is not necessary for System A to keep all the Service A .. N certificates in its key store. System A should only keep the certificate of Service B to call it and then Service B should have kept the certificate of Service C in its Keystore.
|