carbondata-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jackylk <...@git.apache.org>
Subject [GitHub] carbondata pull request #1711: [CARBONDATA-1754][BugFix] Fixed issue occurin...
Date Fri, 05 Jan 2018 06:45:00 GMT
Github user jackylk commented on a diff in the pull request:

    https://github.com/apache/carbondata/pull/1711#discussion_r159816797
  
    --- Diff: integration/spark2/src/main/scala/org/apache/spark/sql/execution/command/management/CarbonAlterTableCompactionCommand.scala
---
    @@ -79,6 +81,14 @@ case class CarbonAlterTableCompactionCommand(
           relation.carbonTable
         }
     
    +    val isLoadInProgress = SegmentStatusManager.checkIfAnyLoadInProgressForTable(table)
    +    if (isLoadInProgress) {
    +      val message = "Cannot run data loading and compaction on same table concurrently.
" +
    +                    "Please wait for load to finish"
    +      LOGGER.error(message)
    +      throw new Exception(message)
    --- End diff --
    
    Better to create a new exception class for this kind of error, you can name it `ConcurrentOperationException`.
We can use this in other similar places in the future.


---

Mime
View raw message