Skip to content

Commit

Permalink
[CARBONDATA-3302] [Spark-Integration] code cleaning related to Carbon…
Browse files Browse the repository at this point in the history
…CreateTable command

## What changes were proposed in this pull request?
Extra check to validate whether the stream relation is not null , moreover condition can be optimized further, currently the condition has path validation whether path is part of s3 file system and then system is  checking whether the stream relation is not null, thi check can be first as this overall condition has to be evaluated for stream table

## How was this patch tested?

Manual testing and existing testcases
  • Loading branch information
sujith71955 committed Feb 24, 2019
1 parent 99dfcbe commit 289d2e4
Showing 1 changed file with 2 additions and 2 deletions.
Expand Up @@ -78,8 +78,8 @@ case class CarbonCreateTableCommand(
path
}
val streaming = tableInfo.getFactTable.getTableProperties.get("streaming")
if (path.startsWith("s3") && streaming != null && streaming != null &&
streaming.equalsIgnoreCase("true")) {
if (streaming != null &&
streaming.equalsIgnoreCase("true") && path.startsWith("s3")) {
throw new UnsupportedOperationException("streaming is not supported with s3 store")
}
tableInfo.setTablePath(tablePath)
Expand Down

0 comments on commit 289d2e4

Please sign in to comment.