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

Middlewares added after a feature is instantiated do not get hooked into a feature's internal streams #118

Open
kyhule opened this issue Dec 2, 2019 · 1 comment

Comments

@kyhule
Copy link
Contributor

kyhule commented Dec 2, 2019

This may be by design but it was not immediately obvious and drove me insane this morning. I was looking for the logging for an Actor in one of my Features but I was not getting any output. Turned out that a refactor recently had the side-effect of the Feature being instantiated before the LoggingMiddleware was added.

Is this a case that could be handled or if not, maybe it is worth calling attention to in the wiki.

@ShikaSD
Copy link
Contributor

ShikaSD commented Dec 9, 2019

Hi @kyhule , sorry for long reply times :)
It is intended by design to have middleware added before the feature.

The general idea is to create them before anything else is instantiated, and then use WrappingCondition and different selectors to determine whether to add middleware or not.

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