datacube.index.abstract.AbstractDatasetResource.add

abstract AbstractDatasetResource.add(dataset, with_lineage=True, archive_less_mature=None)[source]

Add dataset to the index. No-op if it is already present.

Parameters:
  • dataset (Dataset) – Unpersisted dataset model

  • with_lineage (bool) –

    • True (default) attempt adding lineage datasets if missing

    • False record lineage relations, but do not attempt adding lineage datasets to the db

  • archive_less_mature (int | None) – if integer, search for less

mature versions of the dataset with the int value as a millisecond delta in timestamp comparison

Return type:

Dataset

Returns:

Persisted Dataset model