Skip to content

Commit a4381e0

Browse files
bubriksSirOibaf
andcommitted
[FSTORE-1591] Example on how to create a table with table space (#417)
Co-authored-by: Fabio Buso <fabio@hopsworks.ai>
1 parent 6f859e6 commit a4381e0

File tree

1 file changed

+29
-0
lines changed

1 file changed

+29
-0
lines changed

docs/user_guides/fs/feature_group/create.md

+29
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,35 @@ When you create a feature group, you can specify the table format you want to us
8989

9090
During the creation of a feature group, it is possible to define the `storage_connector` parameter, this allows for management of offline data in the desired table format outside the Hopsworks cluster. Currently, only [S3](../storage_connector/creation/s3.md) connectors and "DELTA" `time_travel_format` format is supported.
9191

92+
##### Online Table Configuration
93+
94+
When defining online-enabled feature groups it is also possible to configure the online table. You can specify [table options](https://docs.rondb.com/table_options/#table-options) by providing comments. Additionally, it is also possible to define whether online data is stored in memory or on disk using [table space](https://docs.rondb.com/disk_columns/#disk-columns).
95+
96+
The code example shows the creation of an online-enabled feature group that stores online data on disk using `ts_1` table space and sets several table properties in the comment section.
97+
98+
```
99+
fg = fs.create_feature_group(
100+
name='air_quality',
101+
description='Air Quality characteristics of each day',
102+
version=1,
103+
primary_key=['city','date'],
104+
online_enabled=True,
105+
online_config={'table_space': 'ts_1', 'online_comments': ['NDB_TABLE=READ_BACKUP=1', 'NDB_TABLE=PARTITION_BALANCE=FOR_RP_BY_LDM_X_2']}
106+
)
107+
```
108+
109+
!!! note Table Space
110+
The table space needs to be provisioned at system level before it can be used. You can do so by adding the following parameters to the values.yaml file used for your deployment with the Helm Charts:
111+
112+
```yaml
113+
rondb:
114+
resources:
115+
requests:
116+
storage:
117+
diskColumnGiB: 2
118+
```
119+
120+
92121

93122
#### Streaming Write API
94123

0 commit comments

Comments
 (0)