0.7 to 0.8 Upgrade Guide
Overview
Version 0.8 of the SDK comes with performance and cost improvements, new capabilities to define more powerful features, the ability to manage releases of the Tecton Materialization Runtime, and an enhanced development experience. It also includes minor changes to the behavior and naming of some Tecton objects, methods, and CLI commands. Read the general Upgrade Process page in addition to the following documentation for guidance on how to safely upgrade from 0.7 to 0.8.
To ensure a safe upgrade, Tecton
disallows any destructive changes
(i.e. Recreates) to your Feature Repository while upgrading. For example,
tecton apply
will prevent
changes to a Feature View's Offline Store format
while upgrading as this would normally cause re-materialization.
Step-by-Step Upgrade Flow
These are the most important changes in Tecton 0.8:
- Materialization clusters are required to
pin a specific version of
the
tecton
library (using thetecton_materialization_runtime
on Batch Feature Views, Stream Feature Views, and Feature Tables). - The default Offline Store format is changing from Parquet to Delta.
- Tecton is introducing a new required Repo Config
.yaml
file to configure defaults in your Feature Repository. - Stream jobs for Spark-based Stream Feature Views
must run on on-demand instances.
This may be a breaking change if your Feature Repository explicitly sets
instance_availability
tospot
orspot_with_fallback
instream_compute
for Stream Feature Views.
Most customers should follow this guidance while upgrading:
-
Repo Config file: Use Tecton's CLI to generate a
repo.yaml
file with pre-filled defaults fortecton_materialization_runtime
:- If your Feature Repository does not specify an Offline Store format, run
tecton repo-config init --parquet
to explicitly set the default format to Parquet (in order to avoid destructive changes or rematerialization). - Otherwise, run
tecton repo-config init
- If your Feature Repository does not specify an Offline Store format, run
-
Spark-based Stream Feature Views: If
stream_compute
is set, ensure thatinstance_availability
is either not specified, or is set toon_demand
. -
Deprecated Methods, Parameters, or Attributes: Ensure that your Feature Repository does not rely on any Tecton methods, parameters, or attributes that are deprecated or removed in 0.8. This may be a breaking change if your Feature Repository relies on methods, parameters, or attributes removed in 0.8.
Please see the following sections for details on all changes in 0.8.
Changes in 0.8
Versioning of the Tecton Materialization Runtime
Tecton 0.8 introduces versioning of the Tecton Materialization Runtime that is deployed to Databricks & EMR clusters for orchestration of backfills and materialization. This further improves the reliability of Tecton releases beyond our robust testing and validation process by letting customers iteratively upgrade Feature Views and Tables.
In 0.8+, tecton_materialization_runtime
is a required parameter on Batch
Feature Views, Stream Feature Views, and Feature Tables. It must be set to an
exact version of
the tecton
package (e.g. 0.8.0
).
Tecton guarantees +1 support -- for example, features applied with Tecton SDK
0.8 will support Materialization Runtime Versions of 0.8.*
or 0.9.*
.
This means that jobs for Feature Views & Tables applied using any version of
Tecton will no longer automatically update (or automatically restart, in the
case of Stream Feature Views) when Tecton releases changes to the
materialization runtime. Customers should instead upgrade their Feature Views &
Tables by setting the tecton_materialization_runtime
parameter when upgrading
their SDK to a new minor version or when recommended by Tecton Support. Tecton
will also document release notes in the Changelog.
The new Repo Config, described in the following section, helps customers define
a default tecton_materialization_runtime
for all Feature Views & Tables in
their Feature Repository.
Repo Config File
Tecton 0.8 introduces the
Repo Config,
a required configuration file used to set defaults for Tecton objects in a
Feature Repository. This helps developers avoid having to specify certain
parameters for every new Tecton object and ultimately results in simpler feature
definitions. For example, developers can use this file to set a default
tecton_materialization_runtime
for all Feature Views in a Feature Repository.
During tecton plan/apply/test
, Tecton will look for a Repo Config file named
repo.yaml
in the root of your Feature Repository. To specify another file, use
the --config
flag (e.g. tecton plan --config my_config.yaml
).
Tecton will automatically generate a new Repo Config file when initializing a
new Feature Repository using tecton init
. For existing Feature Repositories,
run tecton repo-config init
to generate a Repo Config file named repo.yaml
with pre-filled defaults for tecton_materialization_runtime
.
If you are also explicitly setting the Offline Store version to ParquetConfig
(as described in the
following section), use
tecton repo-config init --parquet
.
Changes to configuring offline_store
offline_store
is an optional parameter used to configure Tecton's Offline
Store for Batch Feature Views, Stream Feature Views, and Feature Tables.
OfflineStoreConfig
Tecton 0.8 introduces the new OfflineStoreConfig
object for configuring
offline_store
and the new
Publish Features
functionality.
The OfflineStoreConfig
object includes an optional parameter
(staging_table_format
) to configure the format of the Offline Store to
DeltaConfig()
or ParquetConfig()
. Before 0.8, this was done by setting
offline_store=ParquetConfig()
or offline_store=DeltaConfig()
.
In 0.8, offline_store
can be set to OfflineStoreConfig
, ParquetConfig
, or
DeltaConfig
. In a future version of Tecton, offline_store
will only support
being set to OfflineStoreConfig
.