-
Notifications
You must be signed in to change notification settings - Fork 90
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
Exposing publishAllOutstanding
as a public API in PublisherInterface
#949
Comments
@kamalaboulhosn @hannahrogers-google @hongalex @feywind for discussion. |
Also @anguillanneuf for discussion. |
I have not used |
The PublisherInterface is used by the Pub/Sub Lite library. It does not implement the What was the reason for switching from |
It made it possible to add trace instrumentation here: GoogleCloudPlatform/spring-cloud-gcp#548. We basically needed a Note that it's impossible to subclass |
Happy New Year! I am going to try switching Spring Cloud GCP to use @kamalaboulhosn Could you confirm/clarify a couple of my assumptions --
|
Hi @elefeint, The only reason we added the PublisherInterface was because we created a Pub/Sub Lite service, as Kamal mentioned. The interface only exposes methods that are implemented by both the Pub/Sub Lite publisher client and the Cloud Pub/Sub publisher client to allow for seamless transition between Cloud Pub/Sub and Pub/Sub Lite. The other methods exposed by the Cloud Pub/Sub publisher client (like publishAllOutstanding) are not implemented by the Pub/Sub Lite client, which is why these methods are not included in the PublisherInterface. Publisher.setTransform is okay to use, even though it has the BetaApi tag. |
Thank you! |
After the discussion in googleapis/java-pubsub#949, reverting back to using `Publisher` for all API return types. I've ported the trace header injection functionality from `TracingPublisher` into `TracingPublisherFactory`. The Trace information will now get into a standard `Publisher` through a builder callback `PubsubMessage.Builder.setTransform()`.
After the discussion in googleapis/java-pubsub#949, reverting back to using `Publisher` for all API return types. I've ported the trace header injection functionality from `TracingPublisher` into `TracingPublisherFactory`. The Trace information will now get into a standard `Publisher` through a builder callback `PubsubMessage.Builder.setTransform()`.
After the discussion in googleapis/java-pubsub#949, reverting back to using `Publisher` for all API return types. I've ported the trace header injection functionality from `TracingPublisher` into `TracingPublisherFactory`. The Trace information will now get into a standard `Publisher` through a builder callback `PubsubMessage.Builder.setTransform()`.
In the last release of Spring Cloud GCP, we switched from returning
Publisher
to returningPublisherInterface
in the convenience "Template" layer. This led to an accidental regression (GoogleCloudPlatform/spring-cloud-gcp#790).Before we proceed with workarounds in Spring Cloud GCP, an API surface question for the client library -- does it make sense to add
publishAllOutstanding()
toPublisherInterface
? Or is it not meant to be part of the public API?The text was updated successfully, but these errors were encountered: