Export and Import Solution

Export and Import

These two features can be found on the GraphStudio Home page.

Legacy solutions exported prior to v3.1 cannot be imported into newer versions due to data storage changes made in v3.1. Contact support@tigergraph.com for guidance to import an older solution.

Export

Click Export Current Solution to start to export the whole solution as a tar file.

export solution

Select the desired content to export in the pop-up dialog box. By default, it will export the schema, the loading jobs, and the queries. You can also choose to only export specific graphs and decide whether to include the graph data.

  • Exporting graph data may take more time.

  • In a cluster environment, the process of exporting data from GraphStudio involves the replication of all data onto a single node. However, if the volume of data is substantial, this process may encounter failures. We recommend utilizing this functionality only for smaller data sizes (less than 10GB).

The exported file also includes metadata that describes the layout of your schema design as well as user-created icons to preserve the design of your GraphStudio solution.

export options

The tar file includes two folders: graph/ and gui/. The graph/ folder includes an ExportedGraph.zip file that contains, but is not limited to, the following files:

  • DBImportExport_<graphName>.gsql command file for each graph called <graphName> in a MultiGraph system. The command file creates the exported graph, including its local vertex, edge, and tuple types, along with its loading jobs, data source file objects and queries.

  • global.gsql - Loading job to create all global vertex and edge types and data sources.

  • tuple.gsql - Loading job to create all User Defined Tuples.

This ExportedGraph.zip file is identical to what is produced by running the database export command with the template option and the data option(if the corresponding checkbox is selected).

The gui/ folder contains all user icons and a json file that describes the layout of the schema in GraphStudio.

  1. The graph data and data files will only be exported when the Data option is checked.

  2. Starting with TigerGraph 3.0, GSQL queries can be run in Interpreted Mode in GraphStudio without installation. These queries need to be installed to be exported.

Import

Click Import an Existing Solution to upload a previously exported tar file.

import solution

In order to optimize the time required for import, the imported queries will not be installed but saved as drafts. You need to install them manually.

Please be extra cautious when importing databases as it can overwrite the current solution, resulting in the deletion of existing schemas, load jobs, queries, and data files. Importing a new solution cannot be undone to restore the previous state, regardless of whether the import succeeds or fails.

Therefore, create a complete backup beforehand in case you need to restore the database: Back up a Database Cluster

For security purposes, TigerGraph has two gadmin commands, GSQL.UDF.Policy.Enable and GSQL.UDF.Policy.HeaderAllowlist to prevent malicious code execution during import. Please refer to the section on UDF Security to ensure that UDFs comply with the security specifications. This will help you import the solution successfully.