-
Notifications
You must be signed in to change notification settings - Fork 345
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
fix(trait): nil pointer dereference when applying traits during kit building #3471
Conversation
I found that the impact of the bug is much broader than Tracing trait. In essence, every trait that is naively implemented assuming I'm trying to create a better fix that solves the issue altogether. |
6fad820
to
ca87efc
Compare
The last commit might be a bit controversial but I find it necessary for the fix. I think Camel trait has actually been influential to kits but hasn't been explicitly specified so. I'd like to make sure I'm not doing something completely wrong, so please review this again. |
Thanks @tadayosi . I think it partially influences the kits. Ie, if the runtime version is changed, then, it makes sense to build a new kit. However, if a property change (a runtime property, as build time property are specified in the |
Thanks. That's very valid point. It also looks not so easy to split the trait and at the same time keep backward compatibility. And some I think there's a bit of mess in traits about what actually influence kits and what do not and their relationship with the return value of the I'll explore another approach that checks possibility of nil integration in every trait, instead of making Camel trait explicitly influencing kits and applying traits that influence kits during kit building. |
4a16907
to
0621da9
Compare
Applied the 2nd approach of thorough nil checking. Good news is that most of the traits are bug free, as they are already guarded with the Integration Phase checking methods which means if Integration is absent they simply return false instead of crashing. Nonetheless I made it explicit by checking |
This issue happened when an trait was enabled at IntegrationPlatform which is implemented not considering possible absence of Integration. Fix apache#3205
0621da9
to
dee83e4
Compare
Fix #3205
Release Note