Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
Improve EthereumListener #1152
base: develop
Are you sure you want to change the base?
Improve EthereumListener #1152
Changes from all commits
27c10b1
8165a2c
53e0173
d2fd027
80fe9f8
7a27d8d
350c5d1
c216d32
9627991
86e7ca4
c54d4b9
acb5e89
06c7022
f643b3c
5fcd91f
7fc9119
e1f739c
2e07934
7bf20ff
e41e31b
ab4754d
b214302
003ae12
7288636
442046b
a06646a
698b59a
feeff0c
d463bd1
0d61180
00d4609
3bd0f73
67e9c6a
d576607
f0bf19a
7ee5811
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think it'll be handy in all cases.
Let's say you need to get
headerValidator
out ofCommonConfig
then you will have to make a tricky call likecommonConfig.headerValidator(commonConfig.systemProperties(), commonConfig.publisher())
instead of justcommonConfig.headerValidator()
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@eugene-shevchenko any thoughts on that?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The method uses only in java config, and as I mentioned earlier such bean definition hides component dependencies. With no arguments option I should invoke three factory methods in method's body to get necessary dependencies. But if you think that no-args option is better I can revert method's signature.
PS: It's sad that java config which should configure
ApplicationContext
only, we use like object factory.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it's not a bad thing if we want to get rid of Spring one day.
It's more deterministic way.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Listener doesn't look the thing which is required for running
BlockchainImpl
. Also old constructor could be used by somebody. I'd prefer to keep both old constructor (and init listener there withEthereumListener.EMPTY
) andwithEthereumListener
method.