Comments (5)
The .awaitRunning()
is not good. It eliminates the purpose of the startAsync()
.
Would be better to use void addListener(ApiService.Listener var1, Executor var2);
to log in case of
failed(ApiService.State from, Throwable failure)
from spring-cloud-gcp.
Another (more expensive, but more explicit) alternative is to make an explicit check for the existence of the Subscription using the getSubscription() method
. We could also create the Subscription if it doesn't exist.
This behaviour should be parameterised.
from spring-cloud-gcp.
@artembilan logging sounds good, however, that still doesn't solve the need from the client code to have an explicit way to inspect/handle subscription errors and have the option to fail/retry/ignore.
@joaoandremartins I like the idea of having the option to auto-create the subscription.
I guess we could combine the two suggested behaviors: we listen on the lifecycle events and "on failure" we can inspect if the error is due to missing subscription ("NOT_FOUND: Resource not found (resource=[subscription])." and if that's the case we can have a configurable behavior + a status accessible from the client side probably via a status listener?
from spring-cloud-gcp.
Well, in other places we expose the ApplicationEvent
architecture to let end-user to do what is the best for him there. For example ListenerContainerConsumerFailedEvent
in the Spring AMQP: http://docs.spring.io/spring-amqp/reference/html/_reference.html#consumer-events. Or MqttIntegrationEvent
hierarchy: http://docs.spring.io/spring-integration/reference/html/mqtt.html#mqtt-inbound
from spring-cloud-gcp.
This was apparently fixed in a recent version of the google-cloud-pubsub library, as I'm now seeing errors logged when trying to subscribe to a non-existing subscription.
from spring-cloud-gcp.
Related Issues (20)
- Spanner Lazy Loading seems not to be working HOT 1
- SpannerOperations.executeDmlStatement doesn't run Partitioned-DML when it's not performed in transaction. HOT 4
- java.net.MalformedURLException: unknown protocol: gs HOT 7
- PubSubBinderConfiguration is not disabled when PubSub is disabled HOT 1
- Unknown Function Lower or LOWER HOT 2
- Could not find an appender named [STACKDRIVER] HOT 2
- spring-cloud-gcp-starter-sql-postgresql - Connection issue HOT 1
- datastore: BeforeDeleteEvent is not fired if deletion was performed inside of performTransaction method HOT 1
- Traces not propagated to Cloud Trace, StackdriverTraceAutoConfiguration fails with timeout HOT 6
- Is there an equivalent of resilience4j for node.js HOT 1
- Backport SpannerOptions customizer HOT 2
- Could not autowire. No beans of 'PubSubPersonGateway' type found issue in Pub Sub Sample project HOT 4
- Huge amount of ScheduledFutureTask in memory in case pubsub.googleapis.com isn't available HOT 7
- Spring Boot the property spring.jpa.show-sql doesn't work with Datastore HOT 1
- Health Indicator for Cloud Spanner HOT 2
- pubSubHeathContributor timeout exception on start up. HOT 1
- Google Cloud Storage encoded-key problem HOT 3
- X-B3-TraceId different from x-cloud-trace-context HOT 2
- spring-cloud-gcp-starter-pubsub fail on enforcer plugin HOT 1
- springcloud-gcp-starter-pubsub can's sbscribe topic HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from spring-cloud-gcp.