You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
A microservice Server does not have access to system services organically, a service, if required must be assigned manually.
In other words, there is no dependency injection support for the Server implementation and one must set value to the server instance directly.
Describe the solution you'd like
Allow setting a class to the strategy property and when a class is set instantiate it
using the container.
Since the NestMicroservice class is also an application context this shouldn't be an issue.
What is the motivation / use case for changing the behavior?
Some implementation might require more logic and work, for example, a strict bus like the Azure Service Bus will require pre-defined queues/topics so a verification might be required.
Or, an option to create them on the fly.
The text was updated successfully, but these errors were encountered:
A microservice Server does not have access to system services organically, a service, if required must be assigned manually. In other words, there is no dependency injection support for the Server implementation and one must set value to the server instance directly.
This is how it was designed and honestly, I don't see any reason why we should consider rewriting this (all the existing strategies live and should live outside of the container).
Some implementation might require more logic and work, for example, a strict bus like the Azure Service Bus will require pre-defined queues/topics so a verification might be required.
You should expose them as a public API of your strategy then (options object). Unfortunately, passing precalculated/resolved values (from the container) isn't possible yet, but we're tracking this here #2343
Feature Request
Is your feature request related to a problem? Please describe.
A microservice
Server
does not have access to system services organically, a service, if required must be assigned manually.In other words, there is no dependency injection support for the
Server
implementation and one must set value to the server instance directly.Describe the solution you'd like
Allow setting a class to the
strategy
property and when a class is set instantiate itusing the container.
Since the
NestMicroservice
class is also an application context this shouldn't be an issue.What is the motivation / use case for changing the behavior?
Some implementation might require more logic and work, for example, a strict bus like the Azure Service Bus will require pre-defined queues/topics so a verification might be required.
Or, an option to create them on the fly.
The text was updated successfully, but these errors were encountered: