-
Notifications
You must be signed in to change notification settings - Fork 96
Add customizer interface for spring boot integration #434
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
Conversation
Analytics.Builder builder = Analytics.builder(properties.getWriteKey()); | ||
customizerProvider.orderedStream().forEach((customizer) -> customizer.customize(builder)); | ||
return builder.build(); |
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.
This implementation was inspired by Spring Boot's autoconfiguration for the webclient;
Hi @koenpunt all your changes looks pretty well, could you help us to run |
671aec9
to
d713c82
Compare
@edsonjab done! |
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.
All works.
This to allow customization of the client, without having to manually create the client.
d713c82
to
a39b5a2
Compare
Our development and maintenance efforts have shifted to the new Analytics-Kotlin library. We suggest migrating when you can and we are more likely to accept interface suggestions over there. You're also welcome to continue using your fork of this repo of course :) |
We've used the analytics kotlin library before, but it's missing features and we actually switched to the Java library. I think as long as the kotlin library is mobile device oriented and keeps state during the lifetime of an instance the java project shouldn't be abandoned. |
Also, Java-only projects are still a thing, and I can't imagine them adding kotlin just for the Segment integration. @MichaelGHSeg it would be greatly appreciated if this could be reconsidered. |
Hi @koenpunt, please let us know what features are missing in the analytics-kotlin version. We're super interested in making switching easier. As far as adding analytics-kotlin I think it's only kotlin-stdlib, kotlin-coroutines, and analytics-kotlin that would be needed. We recently added a |
I think there is too much missing for the Java library to be put in the background. We switched to the Java library, so can't really give any feedback on the kotlin library. I do think both should be able to exists, and one shouldn't be replacing the other. |
This to allow customization of the client, without having to manually create the client.
This also includes the changes from #433.