Skip to content
Permalink
Browse files
Properly propagate exceptions in SQSClient (#99)
  • Loading branch information
abhishekd0907 committed Oct 19, 2020
1 parent 33d1a63 commit 56a17f4b75e881359b848ea28c504fd8b36adfd5
Showing 1 changed file with 2 additions and 1 deletion.
@@ -220,11 +220,12 @@ class SqsClient(sourceOptions: SqsSourceOptions,
.standard()
.withClientConfiguration(new ClientConfiguration().withMaxConnections(maxConnections))
.withCredentials(instanceProfileCredentialsProvider)
.withRegion(region)
.build()
}
} catch {
case e: Exception =>
throw new SparkException(s"Error occured while creating Amazon SQS Client ${e.getMessage}")
throw new SparkException(s"Error occured while creating Amazon SQS Client", e)
}
}

0 comments on commit 56a17f4

Please sign in to comment.