Kyle Krueger created BAHIR-224:
----------------------------------
Summary: Blank Pubsub Subscription Strings result in unclear
exceptions
Key: BAHIR-224
URL: https://issues.apache.org/jira/browse/BAHIR-224
Project: Bahir
Issue Type: Bug
Components: Spark Streaming Connectors
Reporter: Kyle Krueger
Expected:
An exception to be thrown when a Pubsub subscription fails.
Result:
If a blank pubsub subscription string is accidentally passed to
PubsubUtils.createStream(), the subscription does not fail in an easy to handle
way: instead, it fails later at PubsubInputDStream.receive().
This throws a massive amount of errors to logs by repeating the following.
{quote}20/02/10 17:23:29 WARN
org.apache.spark.streaming.scheduler.ReceiverTracker: Error reported by
receiver for stream 2: Failed to pull messages -
com.google.api.client.googleapis.json.GoogleJsonResponseException: 404 Not Found
{
"code" : 404,
"errors" : [
Unknown macro: \{ "domain" }
],
"message" : "Resource not found (resource=null).",
"status" : "NOT_FOUND"
}
at
com.google.api.client.googleapis.json.GoogleJsonResponseException.from(GoogleJsonResponseException.java:146)
at
com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest.newExceptionOnError(AbstractGoogleJsonClientRequest.java:113)
at
com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest.newExceptionOnError(AbstractGoogleJsonClientRequest.java:40)
at
com.google.api.client.googleapis.services.AbstractGoogleClientRequest$1.interceptResponse(AbstractGoogleClientRequest.java:321)
at com.google.api.client.http.HttpRequest.execute(HttpRequest.java:1065)
at
com.google.api.client.googleapis.services.AbstractGoogleClientRequest.executeUnparsed(AbstractGoogleClientRequest.java:419)
at
com.google.api.client.googleapis.services.AbstractGoogleClientRequest.executeUnparsed(AbstractGoogleClientRequest.java:352)
at
com.google.api.client.googleapis.services.AbstractGoogleClientRequest.execute(AbstractGoogleClientRequest.java:469)
at
org.apache.spark.streaming.pubsub.PubsubReceiver.receive(PubsubInputDStream.scala:258)
at
org.apache.spark.streaming.pubsub.PubsubReceiver$$anon$1.run(PubsubInputDStream.scala:247)
{quote}
--
This message was sent by Atlassian Jira
(v8.3.4#803005)