CogniteFile and CogniteTimeSeries are two special concepts that represent files and time series. A syncer automatically keeps a corresponding asset-centric resource in sync whenever you create or update a node in either of these views.
How syncers work
A concept in a data model is implemented as a view in CDF. A view contains properties that are either connections to other views or mappings to containers — the physical storage of data. See the data modeling documentation for more information about views and containers.CogniteTimeSeries maps to CogniteDescribable (name, description, and similar properties), CogniteSourceable (source, sourceId, and similar properties), and CogniteTimeSeries (time series-specific properties such as type and step).
CogniteFile maps to the same CogniteDescribable and CogniteSourceable containers, plus a CogniteFile container that holds file-specific properties.
When you create a node that has properties in either the CogniteFile or CogniteTimeSeries containers, a syncer automatically creates a corresponding file or time series resource in the asset-centric CDF API. This supports blob data storage for files and high-performance time series data storage.
Example: Create and sync a time series
The following example uses the Python SDK. Files work in the same way. First, create aCogniteTimeSeries node in data modeling:
Working with synced resources
Inserting and retrieving datapoints
Insert datapoints using theCogniteTimeSeries instance ID:
id from the asset-centric time series the syncer created:
Deletion and modification restrictions
The asset-centric time series is linked to theCogniteTimeSeries node and cannot be deleted or modified outside of data modeling.
Attempting to delete through the asset-centric API returns an error:
externalIdmetadataassetIddataSetId
Updating properties through data modeling
To update a DM-controlled property such asname, use the data modeling instances endpoint: