-
Notifications
You must be signed in to change notification settings - Fork 16
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
Revamp library as new fs2-pubsub
#533
Conversation
f6249ac
to
3e777a0
Compare
3e777a0
to
1cba2cd
Compare
👋 What was the motivation for switching from wrapping the Google provided Java SDK to the generated Scala gRPC sources? Was it just to have pure Scala all the way down? Or were their other motivating factors? What types of testing have been done comparing two implementations? Under load as well? |
Hey Zan! Nice to see you here 😸 Main motivation was using pure Scala to avoid dependency hell when two Google libraries are being used and bring different versions of their internal dependencies.
There hasn't been any actual testing comparing the two implementations. But the new library is already in use and we haven't observed any degradation on performance. |
# Conflicts: # fs2-google-pubsub-grpc/src/main/scala/com/permutive/pubsub/consumer/grpc/PubsubGoogleConsumer.scala # fs2-google-pubsub-grpc/src/main/scala/com/permutive/pubsub/consumer/grpc/PubsubGoogleConsumerConfig.scala # fs2-google-pubsub-grpc/src/main/scala/com/permutive/pubsub/consumer/grpc/internal/PubsubSubscriber.scala # fs2-google-pubsub-grpc/src/main/scala/com/permutive/pubsub/producer/grpc/GooglePubsubProducer.scala # fs2-google-pubsub-grpc/src/main/scala/com/permutive/pubsub/producer/grpc/PubsubProducerConfig.scala # fs2-google-pubsub-grpc/src/main/scala/com/permutive/pubsub/producer/grpc/internal/DefaultPublisher.scala # fs2-google-pubsub-grpc/src/main/scala/com/permutive/pubsub/producer/grpc/internal/PubsubPublisher.scala # fs2-google-pubsub-grpc/src/test/scala/com/permutive/pubsub/GrpcPingPongSpec.scala # fs2-google-pubsub-grpc/src/test/scala/com/permutive/pubsub/PubSubSpec.scala # fs2-google-pubsub-grpc/src/test/scala/com/permutive/pubsub/ValueHolder.scala # fs2-google-pubsub-grpc/src/test/scala/com/permutive/pubsub/consumer/grpc/SimpleDriver.scala # fs2-google-pubsub-grpc/src/test/scala/com/permutive/pubsub/producer/grpc/PubsubProducerExample.scala # fs2-google-pubsub-http/src/main/scala/com/permutive/pubsub/consumer/http/PubsubHttpConsumer.scala # fs2-google-pubsub-http/src/main/scala/com/permutive/pubsub/consumer/http/PubsubHttpConsumerConfig.scala # fs2-google-pubsub-http/src/main/scala/com/permutive/pubsub/consumer/http/PubsubMessage.scala # fs2-google-pubsub-http/src/main/scala/com/permutive/pubsub/consumer/http/internal/HttpPubsubReader.scala # fs2-google-pubsub-http/src/main/scala/com/permutive/pubsub/consumer/http/internal/Model.scala # fs2-google-pubsub-http/src/main/scala/com/permutive/pubsub/consumer/http/internal/PubsubReader.scala # fs2-google-pubsub-http/src/main/scala/com/permutive/pubsub/consumer/http/internal/PubsubSubscriber.scala # fs2-google-pubsub-http/src/main/scala/com/permutive/pubsub/http/oauth/AccessToken.scala # fs2-google-pubsub-http/src/main/scala/com/permutive/pubsub/http/oauth/CachedTokenProvider.scala # fs2-google-pubsub-http/src/main/scala/com/permutive/pubsub/http/oauth/DefaultTokenProvider.scala # fs2-google-pubsub-http/src/main/scala/com/permutive/pubsub/http/oauth/GoogleOAuth.scala # fs2-google-pubsub-http/src/main/scala/com/permutive/pubsub/http/oauth/InstanceMetadataOAuth.scala # fs2-google-pubsub-http/src/main/scala/com/permutive/pubsub/http/oauth/NoopOAuth.scala # fs2-google-pubsub-http/src/main/scala/com/permutive/pubsub/http/oauth/OAuth.scala # fs2-google-pubsub-http/src/main/scala/com/permutive/pubsub/http/oauth/RequestAuthorizer.scala # fs2-google-pubsub-http/src/main/scala/com/permutive/pubsub/http/oauth/TokenProvider.scala # fs2-google-pubsub-http/src/main/scala/com/permutive/pubsub/http/util/RefreshableEffect.scala # fs2-google-pubsub-http/src/main/scala/com/permutive/pubsub/producer/http/BatchingHttpPubsubProducer.scala # fs2-google-pubsub-http/src/main/scala/com/permutive/pubsub/producer/http/HttpPubsubProducer.scala # fs2-google-pubsub-http/src/main/scala/com/permutive/pubsub/producer/http/PubsubHttpProducerConfig.scala # fs2-google-pubsub-http/src/main/scala/com/permutive/pubsub/producer/http/internal/BatchingHttpPublisher.scala # fs2-google-pubsub-http/src/main/scala/com/permutive/pubsub/producer/http/internal/DefaultHttpPublisher.scala # fs2-google-pubsub-http/src/test/scala/com/permutive/pubsub/HttpPingPongSpec.scala # fs2-google-pubsub-http/src/test/scala/com/permutive/pubsub/PubSubSpec.scala # fs2-google-pubsub-http/src/test/scala/com/permutive/pubsub/consumer/http/Example.scala # fs2-google-pubsub-http/src/test/scala/com/permutive/pubsub/producer/http/ExampleBatching.scala # fs2-google-pubsub-http/src/test/scala/com/permutive/pubsub/producer/http/ExampleEmulator.scala # fs2-google-pubsub-http/src/test/scala/com/permutive/pubsub/producer/http/ExampleGoogle.scala # fs2-google-pubsub/src/main/scala/com/permutive/pubsub/consumer/ConsumerRecord.scala # fs2-google-pubsub/src/main/scala/com/permutive/pubsub/consumer/decoder/MessageDecoder.scala # fs2-google-pubsub/src/main/scala/com/permutive/pubsub/producer/AsyncPubsubProducer.scala # fs2-google-pubsub/src/main/scala/com/permutive/pubsub/producer/Model.scala # fs2-google-pubsub/src/main/scala/com/permutive/pubsub/producer/PubsubProducer.scala # modules/fs2-pubsub/src/main/scala-2.12/fs2/pubsub/GrpcConstructors.scala # modules/fs2-pubsub/src/main/scala/fs2/pubsub/circe/package.scala # modules/fs2-pubsub/src/main/scala/fs2/pubsub/package.scala
💻 How to review this PR?
This PR was created with the idea of being reviewed commit by commit. Each commit contains an incremental change that makes it easier to review. Also some of the commits contain additional information in their description to help understand why the change was made.
I also recommend checking "Hide whitespace" when reviewing this PR!
🚀 What's included in this PR?
This PR revamps the library as a new
fs2-pubsub
.The new library includes several improvements over the previous one, such as builder-pattern for creating the publishers/subscribers, better utilities around message or error handling or pureconfig support.
I recommend checking out the
README.md
added in the last step to see how the new library works.