⚠️Beta

gx beta [-hqvV]

Sub-commands under gx beta are still under active development and are subject to change.

1. app-resolve

gx beta app-resolve -c /path/to/app.yaml

Resolves all imports and prints the final YAML config.

This is useful for viewing the entire generated app.yaml when working with imports.

2. data export/import

The data commands allow exporting topic and table data from one Grainite server and importing it into another Grainite server.

Options

  1. --export-dir : the destination/source for exporting data or importing data.

    • Default - ${PWD}/export

  2. --type : The type of data to be exported/imported.

    • Default - ALL

    • Options:

      • ALL - Export/Import topic events, table grains, and grain maps.

      • TABLES - Export/Import only table grains, and grain maps.

      • TABLES_NO_MAPS - Export/Import only table grains.

      • TOPICS - Export/import only topic events.

  3. --threads : Number of threads to use for parallel processing.

    1. Default - 16

data export

gx beta data export

This command will read data from all the apps on the server and write to the provided --export-dir location.

Options

  1. --overwrite : Overwrite existing exported data and continue.

    • Default - false

  2. --skip-existing-apps : Ignore existing app data during export.

    • Default - false

    • If an export for an app already exists in the --export-dir, this flag can be used to skip exporting those apps again.

  3. -g : The number of Grains to inspect per Table to determine which apps contain data.

    • Default - 100

    • This is the number of Grains that gx will dump all 200 maps for to determine which maps contain data.

data import

gx beta data import

This command will read exported data from the provided --export-dir location and import it into the Grainite server.

Please ensure that the app is loaded before running this command.

Options

  1. --concurrent-requests : Specifies the total number of in-flight requests for inserting data into Grainite.

    • Default - 100

Last updated