Skip to content

Commit

Permalink
#184 Add the method to the Source trait that should make performance …
Browse files Browse the repository at this point in the history
…optimization possible in the future.
  • Loading branch information
yruslan committed Apr 6, 2023
1 parent 8f26df1 commit 173b6c0
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions pramen/api/src/main/scala/za/co/absa/pramen/api/Source.scala
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,14 @@ import java.time.LocalDate
* Transfer jobs are used to read data from a source and write it to a sink.
*/
trait Source extends ExternalChannel {
/**
* If true, getRecordCount() won't be used to determine if the data is available.
* This saves performance ond double data read for
* - File sources when input files are always available (lookup tables for instance)
* - Snapshot-based sources.
*/
def isDataAlwaysAvailable: Boolean = false

/**
* Returns the record count based on the particular input period and query.
*/
Expand Down

0 comments on commit 173b6c0

Please sign in to comment.